Guidelines of Ubuntu host

SSH


reference:
How to Enable SSH on Ubuntu 18.04

SAMBA


→ anonymous NAS samba server

reference:
Ubuntu 16.04: sambaをインストールしてWindows 10とファイル共有する
recipe:
/etc/samba/smb.conf
+ [share]
+ comment = share directory
+ path = $PATH
+ read only = no
+ browseable = yes
+ guest ok = yes
+ share modes = yes
permission:
sudo chown -R nobody:nogroup $PATH

→Resources

# Name Category Reference Description
1 How to create a Samba share that is writable from Windows without 777 permissions? tutorial share folder permission
2 DVD ROM shares in SAMBA tutorial share cd drive
3 How to start samba server automatically tutorial differences between systemctl and service

→Workflow

# Name Description Code File
1 Installation, create directory, chown to share user [1]
sudo apt-get install samba
sudo mkdir ~/Share
sudo adduser --system sharer
sudo chown -R sharer ~/Share/
sudo nano /etc/samba/smb.conf

+ [share]
+ comment = share directory
+ path = /home/trancemania/Share
+ read only = no
+ browseable = yes
+ guest ok = yes
+ public = yes
+ writeable = yes
+ share modes = yes
+ create mode = 0777
+ directory mode =0777
+ force user = sharer

sudo service smbd start
/etc/samba/smb.conf
2 Share CD Drive [2] modify /etc/samba/smb.conf
sudo nano /etc/samba/smb.conf

+ [cd-drive]
+ path = /cdrom
+ browseable = yes
+ read only = no
+ guest ok = yes
+ public = yes
+ locking = no
+ force user = sharer
+ preexec = /bin/mount /cdrom
+postexec = /bin/umount /cdrom

sudo service smbd restart
same as above

VNC


→ Ubuntu VNC grey screen

reference:
Ubuntu 15.10安装VNC灰屏的问题
solution:
~/.vnc/xstartup
#!/bin/sh
xrdb $HOME/.Xresources
xsetroot -solid grey
#x-terminal-emulator -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
#gnome-session &
# exec gnome-session &
# Fix to make GNOME work
export XKL_XMODMAP_DISABLE=1
#/etc/X11/Xsession
# /etc/X11/xinit/xinitrc
#!/bin/sh
# Uncomment the following two lines for normal desktop:
# export XKL_XMODMAP_DISABLE=1
unset SESSION_MANAGER
# exec /etc/X11/xinit/xinitrc
unset DBUS_SESSION_BUS_ADDRESS
gnome-panel & gnome-settings-daemon &
metacity &
nautilus &
gnome-terminal &
conclusion:
This way provides a way to access remote Ubuntu host as a non-root account, for root VNC, check X11VNC.

→ Resources

# Name Category Reference Description
1 How to Install and Configure VNC on Ubuntu 18.04 tutorial all in all vncserver tutorial

→Workflow

# Name Description Code File
1 Installation [1] install Xfce desktop environment and main program see [1]
2 Configuration [2] config graphical desktop Xfce to connect, and make the config file executable
sudo nano ~/.vnc/xstartup

+ #!/bin/bash
+ xrdb $HOME/.Xresources
+ startxfce4 &

sudo chmod +x ~/.vnc/xstartup
3 Autostart as system service [3] VNC starts up as system service when reboots see [3] /etc/systemd/system/vncserver@.service

Resilio Sync


→ set up Resilio Sync on Ubuntu

reference:
installation - https://help.getsync.com/hc/en-us/articles/206178924
use - https://help.getsync.com/hc/en-us/articles/204762449-Guide-to-Linux

→ some basic command using Resilio Sync on Ubuntu

systemctl start/restart/stop resilio-sync

→ LAN access to webUI of Ubuntu Resilio Sync

solution:
revise /etc/resilio-sync/config.json as
7c7
<         "listen" : "127.0.0.1:8888"
---
>         "listen" : "0.0.0.0:8888"
then restart resilio-sync

→ Resources

# Name Category Reference Description
1 Installing Sync Package On Linux tutorial resilio-sync installation tutorial
2 Running Sync In Configuration Mode tutorial for LAN access
3 Configuring WebUI tutorial modify config file

→Workflow

# Name Description Code File
1 Installation [1] add source.list and install using apt-get see [1]
2 Create Sync folder create Sync folder and grant permission and possesion
sudo mkdir ~/Sync
sudo chmod g+rw /home/trancemania/Sync/
sudo chown -R rslsync:trancemania ~/Sync/
3 modify config file config script to listening
sudo nano /etc/resilio-sync/config.json

- "listen" : "127.0.0.1:8888"
+ "listen" : "0.0.0.0:8888"
4 run Sync in config mode for LAN access
sudo systemctl enable resilio-sync
sudo service resilio-sync stop
sudo rslsync --config /etc/resilio-sync/config.json

FTP


→ vsftpd settings

reference:
https://www.server-world.info/query?os=Ubuntu_16.04&p=ftp

ARIA2


→Resources

# Name Category Reference Description
1 Startup daemon systemd tutorial aria2 startup script
2 用Aria2解除百度网盘限速(资源已打包, 过程超详细) tutorial aria2: from installation to YAAW to baidu Yun plugin
3 为 Aria2 添加 Tracker 服务器 tutorial add tracker to aria2
4 YAAW for Chrome plugin YAAW - chrome plugin - main program
5 YAAW github page tutorial YAAW official github page
6 aria2 official site homepage aria official site
7 关于aria2最完整的一篇 tutorial another tutorial
8 BaiduExporter plugin available BaiduExporter program
9 tracker patch best aria2 trackers

→Workflow

# Name Description Code File
1 Installation [1]
2 create aria2 folder root directory, download directory, session file and config for aria2; session file is blank, aria2.conf refers to [1] [2] using token secret method, copy this file to new PC. Note use full path rather than relative path in conf file, add trackers [2.1] [2.2]
sudo mkdir $HOME/.aria2
sudo mkdir $HOME/.aria2/download
sudo touch $HOME/.aria2/aria2.session
sudo touch $HOME/.aria2/aria2.conf
sudo nano $HOME/.aria2/aria2.conf
sudo aria2c --conf-path=$HOME/.aria2/aria2.conf -D
$HOME/.aria2/aria2.conf
3 Autostart [3] Autostart as system service when boot up
sudo touch /lib/systemd/system/aria2.service
sudo nano /lib/systemd/system/aria2.service
sudo systemctl daemon-reload
sudo systemctl enable aria2.service
sudo systemctl start aria2
sudo reboot
/lib/systemd/system/aria2.service
4 YAAW installation and settings of Yet Another Aria2 Web, settings
5 Install BaiduExporter [4] follow [4], open baidu pan source pages, setting1, setting2 YAAW official github page

GPU driver


→Resources

# Name Category Reference Description
1 Disable/blacklist Nouveau nvidia driver on Ubuntu 20.04 step by step instructions tutorial
2 Upgrade to 18.04 from 16.04: cannot boot into desktop tutorial

DNS


→ DNS for 20.04

reference:
Set custom DNS servers on Ubuntu 18.04 or 20.04
yaml expected mapping
DNS issues after upgrading to 20.04

FRP


→ FRP

reference:
【司波图】FRP内网穿透教程,看得完你就会了

SOLR


→ solr: Happy Searching

reference:
/lucene/solr/8.9.0
https://solr.apache.org/guide/8_9/installing-solr.html
Elasticsearch快速入门之简介
Apache Solr 8 - Getting Started Tutorial
Solr Schema - Configure and Post Files to an Apache Solr Core
Solr Fields - Field and Field Type Properties in Apache Solr