Skip to content

Instantly share code, notes, and snippets.

@fjolublar
Last active June 25, 2020 08:46
Show Gist options
  • Save fjolublar/936a5bc17187d42825145256c062afb6 to your computer and use it in GitHub Desktop.
Save fjolublar/936a5bc17187d42825145256c062afb6 to your computer and use it in GitHub Desktop.
System Info for Linux
Manual USB camera settings in Linux
https://www.kurokesu.com/main/2016/01/16/manual-usb-camera-settings-in-linux/
uvcdynctrl libwebcam command line tool
http://www.linux-commands-examples.com/uvcdynctrl
How to add space in TexMaths equation
https://ask.libreoffice.org/en/question/209748/how-to-add-space-in-texmaths-equation/
50 UNIX / Linux Sysadmin Tutorials
https://www.thegeekstuff.com/2010/12/50-unix-linux-sysadmin-tutorials/
50 Most Frequently Used UNIX / Linux Commands (With Examples)
https://www.thegeekstuff.com/2010/11/50-linux-commands/
7 Linux hwclock Command Examples to Set Hardware Clock Date Time
https://www.thegeekstuff.com/2013/08/hwclock-examples/
Full reset of network interface
https://superuser.com/questions/885760/full-reset-of-network-interface
Error message “sudo: unable to resolve host (none)”
https://askubuntu.com/questions/59458/error-message-sudo-unable-to-resolve-host-none
https://crontab-generator.org/
PiShrink
https://github.com/Drewsif/PiShrink
IP Address
https://www.raspberrypi.org/documentation/remote-access/ip-address.md
SSH using Linux or Mac OS
https://www.raspberrypi.org/documentation/remote-access/ssh/unix.md
SSH (Secure Shell)
https://www.raspberrypi.org/documentation/remote-access/ssh/
Linux commands
https://www.raspberrypi.org/documentation/linux/usage/commands.md
20 Handy Raspberry Pi Terminal Commands for Beginners
https://www.lifewire.com/raspberry-pi-terminal-commands-4054108
42 of the Most Useful Raspberry Pi Commands
https://www.circuitbasics.com/useful-raspberry-pi-commands/
SD card cloning using the dd command
https://askubuntu.com/questions/227924/sd-card-cloning-using-the-dd-command
Clone Micro SD Card [Raspberry Pi, Linux, dd]
https://www.cyberpunk.rs/clone-micro-sd-card
$ cat /etc/*release* # Check system version.
$ ls -ltrh /dev/video* # To list all video devices picked up by the kernel:
$ lsusb # To list all devices attached to USB use:
$ lspci # To list all devices attached to PCI use:
$ top # Displays real time performance data of all running processes in a system.
$ htop # Like top but better.
$ cat > file_name.txt # Create a file from cat and write to it. CTR + C for closing it.
dpkg-reconfigure tzdata # Change the Local and Universal time on Rasberry.
$ cat tank_server_multithread_3.py # Open file to check.
$ ssh [email protected] # Connect with SSH client:
$ scp * [email protected]:~ # Securely copy files from a device to another.
$ mv file.tar ./Doc # Move files from a directory to another.
$ sudo sudo pkill mosquitto # Kill the service with the name or PID.
$ sudo lsof -i -P -n | grep LISTEN # Check open ports in the system.
$ sudo netstat -ap | grep 8484 # Check the status of the port being used or not.
ping -I wlan0 time.google.com # Ping with defined network interface.
$ CTRL + Z # Shunts the process into the background, suspended.
$ CTRL + C # Interrupt (kill) the current foreground process running in in the terminal.
$ CTRL + D # Close the bash shell. Similat to exit.
$ CTRL + L # Clear the screen. This is similar to running the “clear” command.
$ CTRL + A or Home # Go to the beginning of the line.
$ CTRL + E or End # Go to the end of the line.
$ CTRL + ALT + UP or Down # Go to the other Workspace in Ubuntu.
If ubuntu locks up, try REISUB. It`s better than Cold Rebooting.
Holding ALT and PRINT_SCREEN press R E I S U B . Reboot Even If System Utterly Broken.
https://askubuntu.com/questions/4408/what-should-i-do-when-ubuntu-freezes
$ \time #time option doesn't work
#time is not a builtin; I mean it's not treated as a command; it's a keyword.
#That's why tricks like \time work.
$ \time -v python3 time_check.py #Display different times that the python script took to run.
$ python3 -mprofile time_check.py #Check python-script time performance.
#-------------Creating an Image from SD-card and vice-versa------------#
$ sudo fdisk -l #Check SD-card name.
$ sudo umount /dev/mmcblk0p0 #Unmount the SD-card partitions.
$ sudo dd if=/dev/mmcblk0 of=~/raspbian_backup.img #Create an Image from an SD-card.
$ sudo dd if=~/raspbian_backup.img of=/dev/mmcblk0 #Copy the image to an SD-card.
$ sudo pishrink.sh raspbian_backup.img #Shrink the Pi Image. *First install pishrink*
The Wonder Shaper 1.4.1
https://github.com/magnific0/wondershaper
RTNETLINK answers: Invalid argument / We have an error talking to the kernel #17
https://github.com/magnific0/wondershaper/issues/17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment