forked from HawksRepos/PTS-Team
-
Notifications
You must be signed in to change notification settings - Fork 55
Linux Commands 101
PhysK edited this page Jan 22, 2020
·
2 revisions
.
cd /home/$USER
### Takes you to the current user’s home directory
~
### Takes you to the current user’s home directory
sudo <command>
### execute <command> with root privileges [you will be asked for your password]
mkdir myprettyfolder
### Makes a directory called myprettyfolder (example)
rm file.txt
### Removes a file in the current directory called file.txt
rm -f file.txt
### Removes a file in the current directory called file.txt
### the '-f' flag deletes the file WITHOUT ASKING FOR CONFIRMATION
### '-f' stands for 'force'
rm fi*
### Removes all files that start with fi in the current directory
rm -r fi*
### Removes all files AND DIRECTORIES that start with fi in the current directory
### Contents of directories starting with "fi" will also be removed.
### '-r' means 'recursive'
sudo su
### Switch to root
exit
### Return to your regular user (after using sudo su to become root user)
clear
### Clear the current screen
bash myscript.sh
### Execute the bash script called myscript.sh in current directory
chmod myscript.sh 777
### Allow all permissions for all groups (bad practice)
chmod +x myscript.sh
### Allows the script to be executed when called upon
sudo reboot
### Reboot your server
sudo systemctl status sonarr
### Check on the service called 'Sonarr'
sudo systemctl restart sonarr
### Restarts the service called 'Sonarr'
sudo docker rm -f portainer
### An example of moving a specific container by names
stat /path/to/file
### An example of seeing folder ownership and groups easily
Visit our Webite by Clicking the Picture Below!
Wiki - Wiki
- Recommended Pre-Reading
- Server - Storage Planning
- Usenet or BitTorrent
- PTS Editions
- PTS Folder Structure
- PTS-Repos
- Common Issues
Data Transport
- Traefik
- Port Guard
- PTS Shield
- PTS Press
- Google Cloud - GCE
- Hetzner Cloud
- PTS Fork
- Extra PTS Commands
- PTS Vault - Data Storage
- PTSPatrol
- Plex AutoScan in Docker Container
- Plex_Dupefiner
- Traktarr
- System & Network Auditor
- PreInstaller & UnInstaller
Core Apps [Expand]
Community Apps [Expand]
- AirSonic
- Bazarr
- Bitwarden
- BookSonic
- cAdvisor
- Cloud Commander
- Deluge
- DelugeVPN
- Dozzle
- Duplicati
- Filebrowser
- FlexGet
- Gazee
- Headphones
- Heimdall
- HomeAssistant
- jd2-openvpn
- Kitana
- Logarr
- MakeMKV
- MariaDB
- McMyadmin
- MEDUSA
- Mellow
- Miniflux
- Monitorr
- Muximux
- Mylar
- NextCloud
- NowShowing
- NZBHydra2
- Organizr
- plpp
- pyLoad
- qBittorrent
- QBittorrent VPN
- radarrsyncarr
- Resilio
- rflood-openvpn
- rutorrent-openvpn
- Shoko Anime Server
- SpeedTest
- SyncLounge
- Teamspeak3
- The Lounge
- Transmission
- Trakt.or
- Ubooquity
- Varken
- vnc-xfce
- vnstat
- ZeroTier