1.
sudo apt updatesudo apt install mysql-serversudo mysql_secure_installationrootIn Ubuntu systems running MySQL 5.7 (and later versions), the root MySQL user is set to authenticate using the
auth_socketplugin by default rather than with a password. This plugin requires that the name of the operating system user that invokes the MySQL client matches the name of the MySQL user specified in the command, so you must invokemysqlwithsudoprivileges to gain access to the root MySQL user:
sudo mysql
Note: There is a known issue with some versions of PHP that causes problems with
caching_sha2_password. If you plan to use this database with a PHP application — phpMyAdmin, for example — you may want to create a user that will authenticate with the older, though still secure,mysql_native_passwordplugin instead:
CREATE USER 'sammy'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';
ALTER USER 'sammy'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';
Bonus - Create a ROOT like user wilt all the POWER!
GRANT ALL PRIVILEGES ON *.* TO 'user_name'@'localhost' WITH GRANT OPTION;
tl;dr
sudo tar czfv /backup.tar.gz --exclude=/backup.tar.gz --exclude=/dev --exclude=/mnt --exclude=/proc --exclude=/sys --exclude=/tmp --exclude=/run --exclude=/lost+found /
It will create an archive of all your files at /backup.tar.gz, which you can then copy over to another computer/drive and restore your files
sudo mksquashfs / /backup.sqsh -e /backup.sqsh /media /dev /mnt /proc /sys /tmp /run /lost+found
"-e" switch excludes folders you want to exclude
gnu wget
Examples:
wget -r -np -nd -l1 -A "*.md5" https://mxlinux.ipacct.com/MX-Linux/ANTIX/Final/antiX-19/ -P ./mx
‘-r’, ‘--recursive’
Specify recursive download
‘-np’, ‘--no-parent’
Do not ever ascend to the parent directory when retrieving recursively. This is a useful option, since it guarantees that only the files below a certain hierarchy will be downloaded. See Directory-Based Limits, for more details.
‘-nd’, ‘--no-directories’
Do not create a hierarchy of directories when retrieving recursively. With this option turned on, all files will get saved to the current directory, without clobbering (if a name shows up more than once, the filenames will get extensions ‘.n’).
‘-l depth’, ‘--level=depth’
Set the maximum number of subdirectories that Wget will recurse into to depth. In order to prevent one from accidentally downloading very large websites when using recursion this is limited to a depth of 5 by default, i.e., it will traverse at most 5 directories deep starting from the provided URL. Set ‘-l 0’ or ‘-l inf’ for infinite recursion depth.
‘-A acclist’, ‘--accept acclist’
‘-R rejlist’, ‘--reject rejlist’
Specify comma-separated lists of file name suffixes or patterns to accept or reject (see Types of Files). Note that if any of the wildcard characters, ‘*’, ‘?’, ‘[’ or ‘]’, appear in an element of acclist or rejlist, it will be treated as a pattern, rather than a suffix. In this case, you have to enclose the pattern into quotes to prevent your shell from expanding it, like in ‘-A "*.mp3"’ or ‘-A '*.mp3'’.
‘-P prefix’, ‘--directory-prefix=prefix’
Set directory prefix to prefix. The directory prefix is the directory where all other files and subdirectories will be saved to, i.e. the top of the retrieval tree. The default is ‘.’ (the current directory).