Insert a USB drive into your system and identify your USB drive correctly. This is the step you need to take care, because you may format the wrong disk if not correctly identify your disk.
lsblk
Output:
echo "mysql-server mysql-server/root_password password pwd" | sudo debconf-set-selections | |
echo "mysql-server mysql-server/root_password_again password pwd" | sudo debconf-set-selections | |
sudo apt-get -y install mysql-server |
IP ADDRESS :
ip addr show |grep -w inet |grep -v 127.0.0.1|awk '{ print $2}'| cut -d "/" -f 1
Output : 192.168.16.30
I am running an old Dell Laptop as a server with Ubuntu 18.04 on it. Installing Ubuntu on the system was straight forward, but at a certain point you want to close the lid of the laptop. This puts your laptop in sleep, which for a server is not the intended result.
Debians Suspend Wiki page had the right solution for this
grep + echo should suffice:
grep -qxF 'include "/configs/projectname.conf"' foo.bar || echo 'include "/configs/projectname.conf"' >> foo.bar
-q
be quiet-x
match the whole line-F
pattern is a plain stringThis setting is done in the /etc/sudoers file, which drives sudoers to use default security policy plugin for the sudo command under the user privilege specification section.
To allow a user (naim
in the example below) to run all commands using sudo without a password, open the sudoers file:
echo 'naim ALL=(ALL) NOPASSWD:ALL' >>/etc/sudoers
You must be the root user.
cat /dev/null > ~/.bash_history && history -c && >/var/log/lastlog && >/var/log/wtmp && >/var/log/btmp && exit