See also:
- Unix Toolbox @ http://cb.vu — “a collection of Unix/Linux/BSD commands and tasks which are useful for IT work or for advanced users.”; Bro pages.
- Introduction :: cli.fan — Improving your workflow since 2019
Keep in mind to explore:
- runit - a Unix init scheme with service supervision; [HN](https://news.ycombinator.com/item?id=10059896; Svsh - a shell for runit.
- runwhen - a set of utilities for running commands at particular times. [alternate for cron]
- ^^ Both runit and runwhen are part of daemontools slashpackage
Notes
- To convert the
.pub
file intopem
format —ssh-keygen -f rsa.pub -e -m pem
pidof <appname>
returns the pid of the application. useful for killing the app etc..- The sock file for mysql5 installed using macports lives at
/opt/local/var/run/mysql5/mysqld.sock
. You will need this when using thirdy party SQL clients such as Seqel Pro - Use
python_select
to select the default python that is used on your mac. - If a download is corrupted while installing from macports, try
sudo port clean --all <the offending package>
- Upgrade ports and all other software:
sudo port selfupdate
andsudo port upgrade outdated
. - X environment tricks for Mac OS X.
Pick up *NIX skills
- Miguel Icaza’s recommendations. circa 2011. HN
- Bash/Shell productivity tips.
Installing OpenJDK on Mac OSX
-
Download Soylatte
-
Unzip to ~
-
Edit
~/.bashrc
and add these lines:JAVA_HOME=~/java export JAVA_HOME export PATH=~/java/bin:$PATH
-
activate changes with
$source ~/.bashrc
Burning ISO images to CD/DVD from shell
DVD:
$ growisofs -dvd-compat -Z /dev/hdc=dvd.iso
CD: Find out the cd recording device using cdrecord -scanbus
$ $ cdrecord -scanbus
scsibus2:
2,0,0 200) 'HL-DT-ST' 'DVDRAM GH22NS50 ' 'TN01' Removable CD-ROM
Use cdrecord
to burn.
$ cdrecord -v -dao dev=2,0,0 speed=8 file.iso
don’t want namservers handed out by local DHCP server?
Comment out domain-name-servers,
in /etc/dhcp/dhclient.conf
.
Tell apt to add new pgp key to its list
$ curl -s http://someurl/key.pgp | sudo apt-key add -
$ sudo apt-key list
Label Drives using e2label command
$ sudo e2label /dev/sdg1 emdebian
Compiling stuff in 32 bit mode on Mac OSX 10.6
Add these flags to ./configure
.
CFLAGS="-O -arch i386" CXXFLAGS="-O -arch i386" LDFLAGS="-arch i386"
Produce print ready copies of man
docs
$ man -t `man -w tmux` | ps2pdf - tmux.pdf
Change keyboard layout in the shell
$ setxkbmap us
2014/11/25: swapped caps and left-ctrl. Put line below in /etc/default/keyboard
XKBOPTIONS="lv3:ralt_alt,compose:menu,ctrl:nocaps"
and run sudo dpkg-reconfigure keyboard-configuration
and confirm
changes to keep the changes you have made.
find memory usage by a process(?)
$ ps -Ao pid,rsz,args | grep <name>
Enabling anti-aliased fonts on Ubuntu
Edit $IDEA/bin/idea.vmoptions
file and add these options:
-Dswing.aatext=true
-Dawt.useSystemAAFontSettings=lcd
The above options managed to get smooth font rendering on Ubuntu 12.10 using OpenJDK7.
Resources
- Setting up email server etc.,
- Linux inside a git book exploring how booting, initialization, interrupts, system calls, memory management etc., works.
- How to make an operating system
OpenBSD
Minix
- Lessons Learned from 30 Years of MINIX | March 2016 | Communications of the ACM by Andrew S. Tanenbaum
Debian
Measuring stuff
- osquery — allows you to easily ask questions about your Linux and OSX infrastructure. Whether your goal is intrusion detection, infrastructure reliability, or compliance.
Running log of things
- Nixers newsletter — weekly newsletter about *NIX things. This is a slow and steady way to read stuff :)
- division by zero links to *nix afficionados.