I) For Debian For installations in Debian Linux with apt delete the first line in /etc/apt/sources.list. To have available the firewall ufw and the feature Open as administrator in the filemanager install as root caja, caja-admin, the gnome-system-tools and the firewall ufw: sudo apt install --reinstall caja caja-admin gnome-system-tools ufw gufw To enable Bluetooth in Debian use the command sudo apt-get install bluetooth bluez libbluetooth-dev libudev-dev libcap2-bin blueman II) Delete root Trash sudo -i rm -R ./.local/share/Trash/files/* III) For Linuxmint/Ubuntu/Debian Fix broken Packages sudo apt --fix-missing update sudo apt update sudo apt install -f If the aforementioned steps do not work for you, you can try to solve the issue using dpkg. Force dpkg to reconfigure all the pending packages that are already unpacked but need to undergo configuration. The -a flag in the following command stands for All: sudo dpkg --configure -a Pipe grep with dpkg to get a list of all the packages marked as required: sudo dpkg -l | grep ^..r Use the remove flag to delete all the broken packages: sudo dpkg --remove --force-remove-reinstreq Clean up the package cache and install scripts using apt clean: sudo apt clean Reinstall missing packages. Login Loop Ctrl+Alt+F3 (Login in xterm with your username and password) ls -lah|grep -i Xauthority Probably this shows root als Owner und Group and prevents your user login in graphics mode sudo chown your_username:your_username .Xauthority Ctrl+Alt+F7 (Login-Screen and go on) If this does not work, again Ctrl+Alt+F3 sudo ls -lah /tmp sudo chmod 1777 /tmp IV) Install Penguins Eggs curl -fsSL https://pieroproietti.github.io/penguins-eggs-ppa/KEY.gpg | sudo gpg --dearmor -o /etc/apt/trusted.gpg.d/penguins-eggs.gpg echo "deb [arch=$(dpkg --print-architecture)] https://pieroproietti.github.io/penguins-eggs-ppa ./" | sudo tee /etc/apt/sources.list.d/penguins-eggs.list > /dev/null sudo apt update sudo apt install eggs and run it as administrator to produce a system clone or a clone with /home sudo eggs produce or sudo eggs produce --clone V) Open Port 22 in your Home Network 192.168.178.0/24 (replace it with your ip data) sudo ufw allow from 192.168.178.0/24 to any port 22 Open Ports for FTP server vsftpd and Ports 80 for HTTP and 443 for HTTPS in your Home Network sudo ufw allow from 192.168.178.0/24 to any port 20,21,10000:10100 proto tcp sudo ufw allow from 192.168.178.0/24 to any port 443 proto tcp Open Port 443 for any sudo ufw allow proto tcp from any to any port 443 VI) Install FTP server vsftpd and configure as described on my Web-Page a) If you want to use ssl encryption (requires openssl installed), create a self-signed SSL certificate for a year by sudo mkdir /etc/ssl/private (if not yet existing) sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /etc/ssl/private/vsftpd.key -out /etc/ssl/certs/vsftpd.crt See later my file vsftpd.conf b) Install VSFTPD sudo apt install vsftpd Download my vsftpd.conf file from my website and save it in your Downloads directory. Then sudo rm /etc/vsftpd.conf sudo cp ~/Downloads/vsftpd.conf /etc/vsftpd.conf sudo chown root:root /etc/vsftpd.conf sudo chmod 644 /etc/vsftpd.conf If you dont want ssl, comment with # the ssl-related lines at the File end. Add group ftpuser and create the directory /home/ftp for the group ftpuser sudo addgroup ftpuser sudo mkdir /home/ftp sudo chown -R root:ftpuser /home/ftp sudo chmod -R 770 /home/ftp Create group ftpuser and add users with a shell on your machine to the group sudo addgroup ftpuser sudo usermod -a -G ftpuser username (repeat with the usernames for ftpuser having a home directory on your machine and a shell they are restricted to their home directory, if they are not in vsftpd.chroot_list) sudo adduser --shell /bin/false --home /home/ftp/ --no-create-home --ingroup ftpuser username (Repeat with usernames for ftpuser users without a shell, restricted to /home/ftp) Modify /etc/shells sudo sed -i -e '$a/bin/false' /etc/shells Download my file /etc/vsftpd.chroot_list, modify it for your users and copy it to /etc. Read the comments in vsftpd.conf sudo cp ~/Downloads/vsftpd.chroot_list /etc/vsftpd.chroot_list sudo chown root:root /etc/vsftpd.chroot_list sudo chmod 644 /etc/vsftpd.chroot_list Check status, stop, start, restart, enable the ftp service sudo systemctl status vsftpd sudo systemctl stop vsftpd sudo systemctl start vsftpd sudo systemctl restart vsftpd sudo systemctl enable vsftpd (so it starts with boot) Shell Script "ipcheck.sh" for updating pasv_address in /etc/vsftpd.conf #!/bin/bash if [ `/usr/bin/whoami` = 'root' ] then OLDIP=`cat /etc/vsftpd.conf | grep pasv_address | sed -e 's/pasv_address=\([0-9]\{1,3\}\.[0-9]\{1,3\}\.[0-9]\{1,3\}\.[0-9]\{1,3\}\)/\1/'` CURRENTIP=`lynx -dump http://checkip.dyndns.org/ | awk {'print $4'} | grep -e '^[0-9]'` if [ "$OLDIP" != "$CURRENTIP" ]; then echo "$(date +'%a %b %d %T %Y') *** Public IP changed from $OLDIP to $CURRENTIP" >> /var/log/vsftpd/vsftpd.log sed 's/\(pasv_address=\)\([0-9]\{1,3\}\.[0-9]\{1,3\}\.[0-9]\{1,3\}\.[0-9]\{1,3\}\)/\1'$CURRENTIP'/' /etc/vsftpd.conf > /etc/vsftpd.conf.new && mv /etc/vsftpd.conf.new /etc/vsftpd.conf && echo "$(date +'%a %b %d %T %Y') *** Pasv_address setting updated successfully - restarting daemon" >> /var/log/vsftpd/vsftpd.log /etc/init.d/vsftpd restart # this will spam much output in your log terminal # else # echo "$(date +'%a %b %d %T %Y') *** IP check OK - IP unchanged" >> /dev/tty12 fi else echo "Permission denied" fi Save it, make it executable and run it periodically every hour as in my example via /etc/crontab My /etc/crontab; edit yours as administrator # /etc/crontab: system-wide crontab # Unlike any other crontab you don't have to run the `crontab' # command to install the new version when you edit this file # and files in /etc/cron.d. These files also have username fields, # that none of the other crontabs do. SHELL=/bin/sh # You can also override PATH, but by default, newer versions inherit it from the environment #PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin # Example of job definition: # .---------------- minute (0 - 59) # | .------------- hour (0 - 23) # | | .---------- day of month (1 - 31) # | | | .------- month (1 - 12) OR jan,feb,mar,apr ... # | | | | .---- day of week (0 - 6) (Sunday=0 or 7) OR sun,mon,tue,wed,thu,fri,sat # | | | | | # * * * * * user-name command to be executed # Update ipv4 address every 30 minutes */30 * * * * root pkexec /home/rolf/.ADMIN-ROLF/ipcheck.sh 17 * * * * root cd / && run-parts --report /etc/cron.hourly 25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily ) 47 6 * * 7 root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.weekly ) 52 6 1 * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.monthly ) # V) Install apache2, mysql-server, php and phpmyadmin with the Software Manager in Linuxmint or follow installation instructions on Ubuntu or Debain pages. For a LetsEncrypt Certificate of your domain follow the Link https://www.digitalocean.com/community/tutorials/how-to-secure-apache-with-let-s-encrypt-on-ubuntu VI) Check status, start, stop, restart, enable the Web server apache2 sudo systemctl status apache2 sudo systemctl start apache2 sudo systemctl stop apache2 sudo systemctl restart apache2 sudo systemctl enable apache2 VII) Check mySQL and create a password for root sudo mysql mysql> ALTER USER 'root'@'localhost' IDENTIFIED BY '[password]'; mysql> FLUSH PRIVILEGES; mysql> exit; Then login with sudo mysql -u root -p and your chosen password Create a superuser (and afterwards delete user root) mysql>CREATE USER 'your_username'@'localhost' IDENTIFIED BY 'your_password'; mysql>GRANT ALL PRIVILEGES ON *.* TO 'your_username'@'localhost' WITH GRANT OPTION; mysql>CREATE USER 'your_username'@'%' IDENTIFIED BY 'your_password'; mysql>GRANT ALL PRIVILEGES ON *.* TO 'your_username'@'%' WITH GRANT OPTION; mysql>SHOW GRANTS FOR username; mysql>FLUSH PRIVILEGES; mysql>drop user root@localhost; mysql>exit; VIII) Create a Database db0001 mysql -u your_username -p mysql>CREATE DATABASE IF NOT EXISTS db0001; mysql>SHOW DATABASES; mysql>exit;