Site Tools


tech_public:tp_linux (text)

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
tech_public:tp_linux [2025/02/19 16:16] – [Change SFTP default upload permission (umask)] jasonwchtech_public:tp_linux [2025/11/03 20:25] (current) – [CHMOD all files/directories] jasonwch
Line 1: Line 1:
 ====== Linux ====== ====== Linux ======
 +
 +~~stoggle_buttons~~
  
 ===== Linux Mint optimize ===== ===== Linux Mint optimize =====
Line 7: Line 9:
  
 ===== CHMOD all files/directories ===== ===== CHMOD all files/directories =====
-find . -type -exec chmod 770 -- {} ++find . -type -exec chmod 660 -- {} +
  
 find . -type d -exec chmod 2770 -- {} + find . -type d -exec chmod 2770 -- {} +
Line 13: Line 15:
 (-- to prevent name starting with dash as conflict) (-- to prevent name starting with dash as conflict)
  
 +===== Find specific string from directories =====
 +
 +<code>grep -Ril "moment.js" /var/www/html/wiki/lib/plugins/edittable</code>
 ===== Change SFTP default upload permission (umask) ===== ===== Change SFTP default upload permission (umask) =====
  
Line 24: Line 29:
  
 https://help.rapidseedbox.com/en/articles/5999160-how-to-create-an-ssh-key-pair-and-use-it-to-login-as-root-enable-direct-root-ssh-login https://help.rapidseedbox.com/en/articles/5999160-how-to-create-an-ssh-key-pair-and-use-it-to-login-as-root-enable-direct-root-ssh-login
 +
 +===== WINSCP allow sudo command with normal account =====
 +
 +https://winscp.net/eng/docs/faq_su
 +
 +===== Mount SMB v3 from Windows =====
 +
 +  - sudo apt install smbclient cifs-utils
 +  -  mkdir /TARGETFOLDER 
 +  -  Create .credential file ("." stand for hidden file), content: username=XXX password=XXX (separate line).
 +  - CHMOD .credential file to 600
 +  - sudo vi /etc/fstab \\ \\ <code>
 +//XX.XX.XX.XX/SharedFolder /TARGETFOLDER cifs vers=3.0,credentials=.credential,uid=userid,gid=groupid,iocharset=utf8 0 0
 +</code>
 +  - sudo systemctl daemon-reload
 +  - <wrap hi>**Mount drive command: sudo mount /TARGETFOLDER**</wrap>
 +  - <wrap hi>**Force unmount drive command: sudo umount -l /TARGETFOLDER**</wrap>
 +
 +===== Turn off case sensitive from SSH =====
 +
 +<code>
 +sudo nano /etc/inputrc
 +</code>
 +
 +<code>
 +set completion-ignore-case on
 +set show-all-if-ambiguous On
 +</code>
 +
 +restart Terminal
 +
 +===== Add display resolution =====
 +
 +<code>
 +xrandr --newmode "1920x1080_60.00"  173.00  1920 2048 2248 2576  1080 1083 1088 1120 -hsync +vsync
 +xrandr --addmode DP-3 1920x1080_60.00
 +xrandr --output DP-3 --mode "1920x1080_60.00"
 +</code>
 +
 +===== check processor frequency / temperature =====
 +
 +frequency
 +<code>
 +cat /proc/cpuinfo |grep "cpu MH"
 +</code>
 +
 +
 +temperature
 +<code>
 +sensors
 +</code>
tech_public/tp_linux.1739953008.txt.gz · Last modified: by jasonwch (text)

Top ↑