Month: October 2013

  • FIX: RHEL Vbox/Virtualbox extension pack install fail

    I got this on my laptop: Progress state: NS_ERROR_FAILURE VBoxManage: error: Failed to install “/home/klu/tmp/Oracle_VM_VirtualBox_Extension_Pack-4.2.18-88780.vbox-extpack” VBoxManage: error: The installer failed with exit code 127: Error creating textual authentication agent: Error opening current controlling terminal for the process (`/dev/tty’): No such device or address VBoxManage: error: Details: code NS_ERROR_FAILURE (0x80004005), component ExtPackManager, interface IExtPackManager VBoxManage: error:…

  • Bash get full path of file

    Get the full path of a file via: $ readlink -f ./file Tip: make an alias: alias fullpath=’readlink -f’

  • Fix Error mounting: $MFTMirr does not match $MFT (record 0).

    While transferring 200k files to my USB HDD, it stopped and when remounting the disk, I got: Error mounting /dev/sdj1 at /run/media/karlo/WD: Command-line `mount -t “ntfs” -o “uhelper=udisks2,nodev,nosuid,uid=1000,gid=1000,dmask=0077,fmask=0177” “/dev/sdj1” “/run/media/karlo/WD”‘ exited with non-zero exit status 13: $MFTMirr does not match $MFT (record 0). Failed to mount ‘/dev/sdj1’: Input/output error NTFS is either inconsistent, or there…

  • Dell Linux Dock display switcher script

    This might be helpful for someone. A quick script I made for changing output modes on my Dell laptop. There are different configurations. laptop: laptop screen only vga: vga output + laptop screen mix: hdmi + vga output, laptop screen off dock: dell dock display setup #!/bin/bash LAPTOP=’LVDS-1′ DOCKLEFT=’DP-2′ DOCKRIGHT=’DP-1′ VGA=’VGA-1′ HDMI=’HDMI-1′ case $1 in…

  • Openssl encrypt & decrypt files

    by

    in

    Encrypt: openssl enc -aes-256-cbc -a -salt -in plain.txt -out encrypted.enc Decrypt: openssl enc -d -aes-256-cbc -a -in encrypted.enc -out plain.txt Functions: #!/bin/bash function encrypt() { openssl enc -aes-256-cbc -a -salt -in $1 -out ${1}.enc ; stat $_ ; } function decrypt() { openssl enc -d -aes-256-cbc -a -in $1 -out $( echo $1 | sed…