#Linux技巧 阻止ssh自动断开(重发)
cd /etc/ssh
grep ClientAlive sshd_config
cp sshd_config sshd_config.bak
sed -i "s/#ClientAliveInterval 0/ClientAliveInterval 60/g" sshd_config
sed -i "s/#ClientAliveCountMax 3/ClientAliveCountMax 3/g" sshd_config
grep ClientAlive sshd_config
diff sshd_config sshd_config.bak
service sshd reload
再补上一条@literalkernel:
sed -i '/^PasswordAuthentication/c PasswordAuthentication yes' ${SSHD_CONFIG}
#Linux技巧 nohup的使用(重发)
$ nohup my_command > my.log 2>&1 &
$ echo $! > save_pid.txt
#Linux技巧 fg命令(Re-enter interactive mode after Ctrl-z)
fg [jobspec]
Resume jobspec in the foreground, and make
it the current job. If jobspec is not
present, the shell’s notion of the current
job is used. The return value is that of
the command placed into the foreground, or
failure if run when job control is dis-
abled or, when run with job control
enabled, if jobspec does not specify a
valid job or jobspec specifies a job that
was started without job control.
#Linux技巧 端口占用查找
netstat -ntulp |grep 443
自建实例的同学,请务必添加如下两个定时任务,推荐在每天早晨低峰时段运行
RAILS_ENV=production /home/mastodon/live/bin/tootctl media remove --days=14
清理缓存的外站媒体文件,和
RAILS_ENV=production /home/mastodon/live/bin/tootctl media remove-orphans
清理未关联任何 toot 的“无主”媒体文件
另外推荐配合以下任务食用
RAILS_ENV=production /home/mastodon/live/bin/tootctl statuses remove
清理没有同本站任何用户产生关联的 toot 本身(比如跨站轴上收到的、没有本站用户转发/评论/收藏过的消息)
各命令参数请参考 -h 和官方文档按实际情况调整:https://docs.joinmastodon.org/admin/tootctl/
您的钱包会感谢我的╮( ̄▽ ̄")╭
#Linux技巧 nohup的使用
$ nohup my_command > my.log 2>&1 &
$ echo $! > save_pid.txt
#小森林 可以艾特推特用户了(伪)@[email protected]
#Linux技巧 阻止ssh自动断开
cd /etc/ssh
grep ClientAlive sshd_config
cp sshd_config sshd_config.bak
sed -i "s/#ClientAliveInterval 0/ClientAliveInterval 60/g" sshd_config
sed -i "s/#ClientAliveCountMax 3/ClientAliveCountMax 3/g" sshd_config
grep ClientAlive sshd_config
diff sshd_config sshd_config.bak
service sshd reload
#Linux技巧 子目录磁盘占用分析
$ du -h --max-depth=0 *
#BBC 中美关系:美国或公布“中共党员签证禁令”掀起舆论波澜 http://www.bbc.com/zhongwen/simp/world-53445210
Dear Doctor, we have just updated the official stickers “Anecdotes”! Please visit our official website for download~
Click here:
#Arknights #Yostar
http://arknights.global/fankit
#小森林 全文搜索ElasticSearch已启用,又少了700M内存
m.gretaoto.ca 玻璃翼长毛象站欢迎大家入驻。自带跨站关注功能,可在本站关注/订阅 Twitter, Instagram上的用户。
新注册的用户可以到https://m.gretaoto.ca/about/more 了解详情
-----
Welcome to m.gretaoto.ca . We are a custom modified mastodon instance with unique features. You can follow any Twitter and Instagram users on gretaoto.
《科技爱好者周刊(第116期)》:视频会议软件 Zoom 的画面布局,是所有人平均分配屏幕空间。
日本很多用户纷纷反馈,上下级的头像一样大,搞不清楚谁是领导,不好区分地位级别,希望能更改界面。日本网友就画出了日本企业想要的的屏幕布局。
http://www.ruanyifeng.com/blog/2020/07/weekly-issue-116.html
Chinese 🇨🇳 / Dictatorial Admin / Mastodon Code Contributor / 摸鱼技术布道师
Steam: https://steamcommunity.com/id/MashiroBest
Epic: https://store.epicgames.com/en-US/u/d211c824cbd94aaeba898db6bb823ff7
原批交流群:966322309