Ubuntu system commands (updating), ubuntu updating
1. Enable Ubuntu root User:
Set the root password for sudo passwd root (not required once)
Switch su root to the root user
2 disable Ubuntu root users:
Sudo passwd-l root (disabling the root password will not change)
Sudo passwd-u root (enable root account)
3. Download nodejs
1. Sudo apt-get install nodejs
After the installation is complete* Node-v *Check whether the nodejs installation is successful, but the result is that no node command is available.* Js-v *It is valid. It is inferred that nodejs is installed with apt-get, and js is automatically soft connected to nodejs. If you are not used to it, you can create a soft connection to node.
Ln-s/usr/bin/nodejs/usr/bin/node// Bind the global environment
2. sudo apt-get install npm
You don't need to bind the environment.
4. Common commands
DELETE command:
Rm: delete non-empty directories (multiple files can be deleted)
Rmdir: delete an empty directory.
Rm-rf directory name
-R refers to recursion down to manage the number of levels of directories and delete them together.
-F means to delete the file directly without any prompts.
5. Create a command
Mkdir directory name New Folder
Touch file name New File
6. Copy commands
Cp file name target path (copy a file to the target path)
Cp-I (if a file with the same name exists, output [yes/no] to check whether execution is performed)
Cp-f (Force copy file, with the same name not required)
7. Update command
Sudo apt-get upgrade (Update installed packages)
Sudo apt-get update (update source database)