All commands (12,635)


  • 0
    gm convert source.png -transparent white result.png
    andresaquino · 2018-04-10 19:07:36 0
  • Get the total RESIDENT memory used by processes of a specific name. This means this is the MINIMUM used by a process, but some memory could be paged out to swap. Show Sample Output


    0
    pids=$(pidof chrome); for p in ${pids[@]}; do cat /proc/$p/status | grep -i vmrss | awk '{print $2}'; done | while read m; do let t=$t+$m; echo $t; done | echo "$(tail -n 1) kB"
    tyzbit · 2018-04-08 16:43:35 1
  • swap out "80" for your port of interest. Can use port number or named ports e.g. "http"


    1
    lsof -iTCP:80 -sTCP:LISTEN
    indexsmithy · 2018-04-07 16:20:25 0

  • 0
    zypper lp | awk '$5=="security" { print "zypper install -y -n -t patch "$3}' | grep -v "needed" | sh +x
    brennquin · 2018-04-04 22:14:45 0

  • 0
    openssl rsa -in privateKey.pem -out newPrivateKey.pem
    aysadk · 2018-04-04 13:35:54 0

  • 0
    openssl x509 -x509toreq -in certificate.crt -out CSR.csr -signkey privateKey.key
    aysadk · 2018-04-04 13:35:34 0

  • 0
    openssl req -out CSR.csr -key privateKey.key -new
    aysadk · 2018-04-04 13:35:19 0

  • 0
    openssl req -x509 -sha256 -nodes -days 365 -newkey rsa:2048 -keyout privateKey.key -out certificate.crt
    aysadk · 2018-04-04 13:35:03 0

  • 0
    openssl req -out CSR.csr -new -newkey rsa:2048 -nodes -keyout privateKey.key
    aysadk · 2018-04-04 13:34:40 0

  • 0
    openssl pkcs12 -info -in keyStore.p12
    aysadk · 2018-04-04 13:33:29 0

  • 0
    openssl x509 -in certificate.crt -text -noout
    aysadk · 2018-04-04 13:33:15 0

  • 0
    openssl rsa -in privateKey.key -check
    aysadk · 2018-04-04 13:33:00 0

  • 0
    openssl req -text -noout -verify -in CSR.csr
    aysadk · 2018-04-04 13:32:43 0

  • 0
    openssl pkcs12 -export -out certificate.pfx -inkey privateKey.key -in certificate.crt -certfile CACert.crt
    aysadk · 2018-04-04 13:32:20 0

  • 0
    openssl pkcs12 -in keyStore.pfx -out keyStore.pem -nodes
    aysadk · 2018-04-04 13:32:02 0

  • 0
    openssl x509 -outform der -in certificate.pem -out certificate.crt
    aysadk · 2018-04-04 13:31:43 0

  • 0
    openssl x509 -inform der -in certificate.cer -out certificate.pem
    aysadk · 2018-04-04 13:31:06 0

  • 0
    openssl s_client -connect www.paypal.com:443
    aysadk · 2018-04-04 13:30:39 0
  • openssl x509 -noout -modulus -in certificate.crt | openssl md5 openssl rsa -noout -modulus -in privateKey.key | openssl md5 openssl req -noout -modulus -in CSR.csr | openssl md5


    0
    openssl x509 -noout -modulus -in certificate.crt | openssl md5 openssl rsa -noout -modulus -in privateKey.key | openssl md5 openssl req -noout -modulus -in CSR.csr | openssl md5
    aysadk · 2018-04-04 13:29:59 0
  • Update method: 1) Find you current version and release in https://esxi-patches.v-front.de/ESXi-6.5.0.html (You can copy the Build number and Control+F in the page). 2) Run this command release per release, changing the with the name of Imageprofile. As example: esxcli software profile update -d https://hostupdate.vmware.com/software/VUM/PRODUCTION[168/1029] depot-index.xml -p ESXi-6.5.0-20180304001-standard This way is needed because updates arent cumulative, so need to do one by one. Show Sample Output


    0
    esxcli software profile update -d https://hostupdate.vmware.com/software/VUM/PRODUCTION[168/1029] depot-index.xml -p <Release>
    pqatsi · 2018-04-03 13:26:58 0
  • Proxy remote mysql with local port.


    0
    ssh -T -N -L 23306:localhost:3306 root@mysql.domain.com
    jackqt · 2018-04-02 05:34:28 0

  • 0
    echo "[{"Name": "bar"}]" | python -c 'import json,sys;obj=json.load(sys.stdin);print(obj[0]["Name"]);')
    moerin · 2018-03-31 21:31:53 0

  • 0
    genisoimage -o bastion-602-jpa.iso -b boot/syslinux/isolinux.bin -c boot/syslinux/boot.cat -no-emul-boot -boot-load-size 4 -boot-info-table -r -R .
    leatherface · 2018-03-30 12:54:26 0

  • 0
    clear && sleep 5s && curl --silent "http://www.commandlinefu.com/commands/by/dunryc" | grep '<div class="command">'|sed 's/......$//'|sed 's/^.....................................//'|recode html..ascii|awk 'ORS="\n\n\n\n"'
    dunryc · 2018-03-28 20:17:40 0

  • 0
    clear && curl --silent http://www.commandlinefu.com/commands/by/dunryc | grep "div class" | grep command |tr '>' '\n' | grep -v command |sed 's/.....$//'
    dunryc · 2018-03-28 19:16:14 0
  •  < 1 2 3 4 >  Last ›

What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands



Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: