systemctl status default.target # to switch runlevels instantly systemctl isolate graphical.target systemctl isolate multi-user.target ll /etc/systemd/system/default.target #runlevel 3 ln -sf /lib/systemd/system/multi-user.target /etc/systemd/system/default.target #runlevel 5 ln -sf /lib/systemd/system/graphical.target /etc/systemd/system/default.target
Fedora 34 : ssh authorized_keys failed Hint
egrep -i 'pubkey*' /etc/ssh/sshd_config sshd -T|egrep "pubkeyauthentication|pubkeyacceptedkeytypes" Federal Information Processing Standards (FIPS) fips-mode-setup --disable fips-mode-setup --check fips-mode-setup --is-enabled Installation of FIPS modules is not completed. FIPS mode is disabled. update-crypto-policies --set LEGACY update-crypto-policies --show => LEGACY reboot
CentOS 7 : yum update error Hint
yum clean all yum update -y
Fedora 31 : php-fpm as root Hint
vi /etc/php-fpm.d/derp.conf ;user = apache user = root vi /lib/systemd/system/php-fpm.service #ExecStart=/usr/sbin/php-fpm --nodaemonize ExecStart=/usr/sbin/php-fpm --nodaemonize -R systemctl daemon-reload systemctl restart php-fpm
ssh : Remote command execution using a script file Hint
#Run one-line remote command ssh test@host -p22 'hostname -f' #Run Multi-Line Remote Command ssh test@host -p22 << EOF hostname -f EOF #Read Remote File and Run Remotely ssh test@host -p22 './test.sh' #Read my file and run it remotely ssh test@host -p22 'bash -s' < test.sh
fedora 31 : parallel ssh program pssh Hint
# yum install pssh -y # man pssh Connect to host1 and host2, and print "hello, world" from each: pssh -i -H "host1 host2" echo "hello, world" Print "hello, world" from each host specified in the file hosts.txt: pssh -i -h hosts.txt echo "hello, world" Run a command […]
Mac : convert fig animation to pngs Hint
making gif animation $ convert *.png test.gif split gif animation $ convert 'test.gif[0-10]' test%03d.png
resin JVM dump setup Hint : ulimit -c unlimited
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again ulimit -c unlimited
mac : tts lame ffmpeg : aiff m4a mp3 convert Hint
say -v Yuna -o filename.aiff -f filename.txt -r 200 lame filename.aiff filename.mp3 ffmpeg filename.mp3 -i filename.m4a -codec:a libmp3lame -qscale:a 1
CentOS 7 : rpm db error - rebuid Hint
mkdir /var/lib/rpm/out mv /var/lib/rpm/__db* /var/lib/rpm/out yum install ....