Archive for the ‘Linux’ Category

Setup VirtualBox RHEL 6.1 host Windows 2003 guest

December 21, 2011

Also see gist

VirtualBox 2011-12-21 RHEL 6.1 host Windows 2003 guest

# cat createvm.sh
sudo VBoxManage createvm –name Windows2003 \
–basefolder /opt/virtual_box \
–ostype Windows2003 \
–register
sudo VBoxManage modifyvm Windows2003 –memory 768
sudo VBoxManage modifyvm Windows2003 –hwvirtex off
sudo VBoxManage modifyvm Windows2003 –vtxvpid off
sudo VBoxManage modifyvm Windows2003 –vram 32
sudo VBoxManage modifyvm Windows2003 –nic1 bridged –bridgeadapter1 eth0

# cat storage.sh
sudo VBoxManage createhd –size 51200 –filename /opt/virtual_box/Windows2003/c_drive
sudo VBoxManage storagectl Windows2003 –name ‘Ide Controller’ –add ide –sataportcount 2 –bootable on –hostiocache on
sudo VBoxManage storageattach Windows2003 –storagectl ‘Ide Controller’ –port 0 –device 0 –type dvddrive –medium /opt/iso/en_win_srv_2003_r2_standard_cd1.iso
sudo VBoxManage storageattach Windows2003 –storagectl ‘Ide Controller’ –port 1 –device 0 –type hdd –medium /opt/virtual_box/Windows2003/c_drive.vdi

# start headless
VBoxHeadless –startvm Windows2003

# eject virtual CD
sudo VBoxManage storageattach Windows2003 –storagectl ‘Ide Controller’ –port 0 –device 0 –type dvddrive –medium

$ cat virtualbox.repo
[virtualbox]
name=RHEL/CentOS-$releasever / $basearch – VirtualBox
baseurl=http://download.virtualbox.org/virtualbox/rpm/rhel/6.0/$basearch
enabled=1
gpgcheck=1
gpgkey=http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc

Install VirtualBox on RHEL 6.1

December 19, 2011

http://download.virtualbox.org/virtualbox/rpm/rhel/virtualbox.repo

[virtualbox]
name=RHEL/CentOS-$releasever / $basearch - VirtualBox
baseurl=http://download.virtualbox.org/virtualbox/rpm/rhel/6.1/$basearch
enabled=1
gpgcheck=1
gpgkey=http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc

Virtual Machine Hosting on Scientific Linux

December 17, 2011

Just learning

What is sVirt?

Kernel Based Virtual Machine

libvirt is: The virtualization API

QEMU is a generic and open source machine emulator and virtualizer.

Qemu/KVM is the thing.

Red Hat Enterprise – Virtualization Getting Started Guide

Users of RHEL can add the RHEL repo file to /etc/yum.repos.d/.

VirtualBox yum-style repository for RHEL

EL6 supports KVM on 64-bit hosts only.

Oracle VM VirtualBox User Manual

VBoxManage is the command-line interface to VirtualBox.

 

Add sudoer user to Linux

December 17, 2011

Ubuntu 12.10 add sudo user

Ubuntu has disabled root account login by default.

sudo adduser craig
sudo usermod -aG sudo craig

Earlier note

useradd username -G wheel
passwd username
visudo

# uncomment this line

## Allows people in group wheel to run all commands
%wheel  ALL=(ALL)       ALL

# Set up ssh access with requiring a password
ssh-copy-id -i ~/.ssh/id_rsa.pub remote_host

Host HTTP access to ISO Image

December 16, 2011

ISO image at /a/b/xx.iso

Mount point at /home/craig/mnt

sudo mount -o loop -t iso9660 /a/b/xx.iso /home/craig/mnt

cd /home/craig/mnt; sudo webfsd -F

 

Amazon ec2 – First Try

March 17, 2011

Hosting alternatives are linode and slicehost, but let’s try out EC2.

EC2StartersGuide

How To: Getting Started with Amazon EC2

Created a Amazon EC2 Key Pair

sudo apt-get install ec2-api-tools

tmux – the early days

March 15, 2011

I’m in the process of switching from using emacs to using vim and tmux.

Emacs

March 8, 2011

Eshell

Mastering Eshell

zsh

March 8, 2011

Links

zsh web-pages

zsh-lovers

zsh wiki

A User’s Guide to the Z-Shell

Adam’s zsh page

The ZSH Workshop – by Larry Schrof

Linux console with >8 colors

March 8, 2011


Upgrading Linux terminal to 256 Colors

from http://pastelinux.com/2010/12/01/upgrading-linux-terminal-to-256-colors/

VIM!The Amazing thing about being in the world of 2010 is we have so many more advance technologies. When it comes to linux terminal, there are so many wonders that can be done. But how come the default terminal colors are 8?

Go ahead type:

tput colors
see that number 8? ridiculous right?

As of now there is a posibility of 256 colors  usable for the terminal.
Luckily this is easy to make happen!
First install:

sudo apt-get install ncurses-term

and stick the following in your ~/.bashrc and/or ~/.bash_profile:

export TERM=xterm-256color

After you edit your .bashrc or .bash_profile source that same file:

source ~/.bashrc

Now retype that command above

tput colors