Archive for the ‘Linux’ Category
xrdp Remote Desktop — blue screen after login —
adduser xrdp ssl-cert apt-get install xorgxrdp-hwe-18.04
Upgrade from Ubuntu 16.04 to 18.04 —
$ sudo apt update $ sudo apt upgrade $ sudo apt dist-upgrade $ sudo apt-get autoremove $ sudo apt install update-manager-core $ sudo reboot $ sudo do-release-upgrade
Enable SFTP Without Shell Access on Ubuntu —
Step 1 — Creating a New User Step 2 — Creating a Directory for File Transfers There are a number of ways to work around this ownership issue. In this tutorial, we’ll create and use /var/sftp/uploads as the target upload directory. /var/sftp will be owned by root and will be unwritable by other users; the […]
Ubuntu Networking multiple interfaces using DHCP —
nano /etc/dhcp/dhclient.conf Add And remove from global
print_req_error: I/O error, dev fd0, sector 0 —
# rmmod floppy # echo “blacklist floppy” | tee /etc/modprobe.d/blacklist-floppy.conf # dpkg-reconfigure initramfs-tools
Couldn’t execute ‘SHOW FIELDS FROM `host_summary` —
# ( cat /usr/share/mysql/mysql_sys_schema.sql; echo ‘####’ ) | mysql –defaults-file=/etc/mysql/debian.cnf –delimiter=’####’ sys
apt-get No space left on device —
Custom Nginx Maintenance Page —
server { listen 80; server_name mysite.com; root /var/www/mysite.com/; location / { if (-f $document_root/maintenance.html) { return 503; } … # the rest of your config goes here } error_page 503 @maintenance; location @maintenance { rewrite ^(.*)$ /maintenance.html break; } } Now whenever you need to take your site offline, simply create the file maintenance.html in […]
How To Set CPU Scaling Governor to Max Performance (scaling_governor) —
# cat /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor To set the scaling_governor to “performance” mode for each CPU, run: # echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor # echo performance > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor # echo performance > /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor # echo performance > /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor … To verify configuration, run: # cat /sys/devices/system/cpu/cpu*/cpufreq/scaling_governorperformanceperformanceperformanceperformance … To view and compare current frequency to the min and max scaling, […]