Anduin Xue

let today = new Beginning();

Ubuntu


MySQL allow remote connection (For root and other users)

For all Ensure firewall allows 3306 port: sudo ufw allow 3306 Allow MySQL to bind to all ports: sudo vim /etc/mysql/mysql.conf.d/mysqld.cnf Then set bind-address to 0.0.0.0. bind-address = 0.0.0.0 For root user Log in root locally first: mysql -u root -p Replace the host value. mysql GRANT ALL PRIVILEGES ON . TO 'root'@'%' IDENTIFIED BY 'password'; mysql UPDATE mysql.user SET host='%'  …

bash Database Linux Ubuntu Remote Management MySQL

Ubuntu resize an ext4 partition without LVM

This post will tell you how to make the partition extend to full disk after resizing the disk. First, check current usage: sudo df -Th We will resize sdb1. sudo fdisk /dev/sdb n – Create partition p – print partition table g - reset as GPT partition table d – delete a partition q – exit without saving the changes w – write the changes and exit. Run: d This will delete the partiton. Select 1. Run:  …

Linux Ubuntu Disk ext4 fdisk Partition

If a Ubuntu server should run apt upgrade automatically?

Backgrounds Recently, I have a lot of Linux servers created. Those servers are really a lot that I'm tired upgrading those every day. file And I just keep doing the same thing: Login Run sudo apt update Run sudo apt upgrade -y Run reboot Why upgrade those automatically? Save time. Get security updates as soon as possible. Packages are always very clean and new, so less painful to upgrade in one  …

bash Linux Ubuntu Upgrade Crontab Update

Install Cockpit on Ubuntu 22.04

It's simple. Install First: sudo apt install cockpit -y Authentication Ensure you have a user instead of root is in the sudo group. Please follow the instructions from: Best practice for authentication Fix network issue You may see the following error after installation: packagekit cannot refresh cache whilst offline First go to here: cd /etc/netplan/ Create a new profile: sudo touch /etc/netplan/ …

bash Linux Ubuntu Remote Management Cockpit NetworkManager

CaddyV2 tips and examples (How to correctly get user's IP address after a reverse proxy)

Here are some tips when I am using CaddyV2 as a reverse proxy. Directly render HTML somedomain.aiursoft.com { respond / h1Welcome/h1 200 } Reverse proxy on certain address somedomain.aiursoft.com { reverse_proxy /admin http://v2ray:10000 { } } Permenant redirect git.aiursoft.com { redir https://git.aiursoft.cn{uri} permanent } Reversey proxy and add custom header  …

Reverse Proxy Linux Ubuntu Proxy FRP Caddy CaddyV2 IP Address Proxy Protocol

Build a new NFS server with WinServer or Ubuntu and mount it

Windows Server On Windows Server, creating a new NFS server is simple. First install this: file And then click the folder properties. file And enable that. file Ubuntu Run: sudo apt update sudo apt install nfs-kernel-server -y sudo mkdir -p /mnt/nfs_share sudo chown -R nobody:nogroup /mnt/nfs_share/ sudo chmod 777 /mnt/nfs_share/ And edit the configuration: sudo vim /etc/exports Add this: /mnt/  …

Linux Ubuntu File Windows Server Share NFS VMware ESXI Vsphere NAS

Mount Windows SMB folder to Ubuntu

First, install tools: sudo apt install cifs-utils Create a new folder: sudo mkdir /mnt/share To mount: sudo mount -t cifs -o username=your-name //your-server/your-path /mnt/share your-name is your Windows user name. your-server is the server IP address or domain name. your-path is the folder name of that SMB share. After executing, you might need to input the password. <div style="display:inline- …

bash Linux Ubuntu Windows Server SMB Share

Run WeChat in Ubuntu

Install and configure Wine. First, install Wine. sudo apt install wine64 After installing, open winecfg. winecfg Ajust the dpi to a higher value. I'm using 192 for 4K display. file Download and configure fonts Download and configure fonts. Run the following commands: sudo apt install cabextract sudo apt install winetricks winetricks corefonts gdiplus riched20 riched30 Download and install WeChat  …

bash Linux Ubuntu China WeChat Wine

Install Nextcloud on a Ubuntu 20.04\22.04 server

Step 1 - Buy a server and basic configuration You can buy a pure server at Vultr. After you installing a pure Ubuntu, or buying a new cloud Ubuntu server, you need to first finish the basic authentication configuration. Follow instructions here to: Delete other accounts. Create your own account instead of root. Disable password login and force to use SSH key to log in. Disable root account.  …

Web Linux Ubuntu IT Apache2 PHP MySQL Certbot Nextcloud Storage

Best-practice for authentication after creating a new Linux server

This article helps you change the following items if your cloud provider didn't do that for you. Create your own account instead of root. Disable password login and force to use SSH key to log in. Disable root account. Enable sudo without password. Before starting the process, make sure you have a valid SSH key-pair locally. Fist, connect to the server. (With root password). you@local  …

bash Linux Ubuntu SSH

Ubuntu bash experience for Windows Terminal without Linux subsystem

Bash is the major shell client I use. On Windows 10 I really enjoy git-bash. But how to set bash to the default terminal in the new Windows terminal? Brief steps: Install a Linux style shell like git-bash. Install the Windows Terminal Make git-bash the default terminal in Windows Terminal Make the theme looks like Ubuntu style. Allow Ctrl + V to paste Allow starting WT in the directory  …

bash Ubuntu Windows 10 Windows Terminal

Linux Cheatsheet for Windows Users

A notebook for Windows folks like me who struggle to remember Linux commands Before starting Control options Operation Command Example Execute command one by one command1; command2 Execute command1 background command1 & command2 Execute command2 if 1 success command1 && command2 Execute command2 if 1 fail command1 || command2 Reverse the command result !command1 Pipeline options  …

bash Linux Ubuntu

  • 1