Archive

Archive for the ‘VMware’ Category

bin/bash^M: bad interpreter: no such file or directory

December 29th, 2009 4 comments

I got this error recently when trying to execute a bash script in Linux.

bin/bash^M: bad interpreter: no such file or directory

The problem turned out to be the fact that I downloaded it to a windows machine before copying it to the Linux box. When I downloaded it windows added a number of Windows Carriage Returns at the end of each line. Why? Don’t ask me!

After a bit of Googling I found a number of posts that recommended I use dos2unix to convert it into unix file format. Unfortunately I didn’t have this on my system. So instead I used the following command.

tr -d '\r' < inputfile > outputfile

Categories: Linux, VMware Tags:

ThinApp

October 23rd, 2009 2 comments

VMware_ThinApp_logo_01The company I work for, VMware, has a product called ThinApp which allows you to run software without having to install it. Many of you may have downloaded Firefox for example and when you downloaded it you had to ask a lot of questions as it was being installed. Worse if you tried to install it on another computer you might not be able to as you wouldn’t have sufficient privileges on that computer. Such as an internet cafe or some such.

Now however with ThinApp that is no longer a problem. You no longer need to install applications to run them. There is a great site which has created these ThinApps for lots of free software called thindownload.

Categories: Opinion, VMware Tags:

VMware VCP Cheat Sheet

June 12th, 2009 No comments

vcp-logoI was giving the VI3 VCP course there recently and I realised that the handouts didn’t contain the summary from each section. So instead of waiting for each of the students to write it down I decided to just paste them into a word document. It may be useful as a study aid for anyone taking the Vmware VCP exam.

Once VMware PSO release the vSphere4 VCP exam I will get the summary from that for people as well.

You can download the cheatsheet here.  Download vi3-course-summary

Categories: VMware Tags:

Use an SSH proxy to access the internet around a firewall

May 7th, 2009 No comments

I was using an ESX Server as an SSH tunnel to access the webpage of one of my VMs that was on a different network than my laptop today and I thought it might be useful for people.  Particularity if you want to set up a proxy server to access the internet via a Linux system you might have running outside of your corporate firewall. This would be very useful to access sites that are blocked by your company or use it to download bittorrents etc.

What you need is

  • A Linux system on the internet (running at home, a cheap VM (like this site is running on rapidvps.com, or maybe one running on VMware Workstation at home), or maybe your home router)
  • Putty (or a console shell if using Linux)
  • A Web Browser (or any application you want to access the internet, like bittorrent or whatever).

Windows:

  1. First you need to have SSH access to your Linux system. Not necessarily root.
  2. Use Putty to create a connection to your system. But before you connect look at the options on the left.
  3. Select SSH > Tunnels
  4. Here enter a source port of 1080 and select the Dynamic Radio button.
  5. Select add.tunnelport
  6. Next open your session to your linux system
  7. Configure your application to use a Socks proxy over port 1080. For example in Firefox  select Tools > Options > Advanced > Network > Settings and configure it to use a SOCKS proxy as below.

Linux:

  1. First you need to have SSH access to your Linux system. Not necessarily root.
  2. Open an SSH session to your system using the following syntax ssh -D 1080 user@mylinux
  3. Configure your application to use a Socks proxy over port 1080. For example in Firefox select Tools > Options > Advanced > Network > Settings and configure it to use a SOCKS proxy as below.

firefox

X Forwarding:

Also Linux has a cool feature called X Forwarding. If you open a session to a Linux server from a Linux server (or using a program like Exceed in Windows) using the X flag i.e. ssh -X user@mylinux then you can simply open the GUI of the web browser on the remote machine. I use this for bittorrent.

For example there is not much use in proxying bittorroent to my machine in work. I’d mush rather have it downloaded at home. So I ssh -X to my server at home. Run the command ktorrent & and hey presto the Ktorrent GUI opens on my machine in work, but is running at home. So anything I download will be saved at home. Cool eh?

Categories: Linux, VMware Tags:

VMworld Advanced HA Troubleshooting

September 18th, 2008 No comments

Vmworld USMy Advanced HA Troubleshooting presentation is being delivered in VMworld America today at 4PM local time. It’s being delivered by Henry Chu who also works for PSE here in VMware. Hopefully it’ll go well for him, it must be hard to present someone elses content. Anyway if anybody is in VMworld I’d highly recommend checking it out. it was voted 4th best presentation of VMworld Europe so I reckon it’ll be popular.

It would have been nice if i was able to head to Vegas to give it myself but when they were organising it there was a travel freeze on so they weren’t able to send me. Harsh!

Categories: VMware Tags:

ESX – Find large files in the Service Console

April 9th, 2008 No comments

ESX BoxGot a few cases in work over the last few week where people are finding the root file system full in VMware ESX Server. This causes lots of issues with connectivity to VirtualCenter etc. The problem is that often it is difficult to find the large files that are causing the file system to fill up. I’ve been sending people this handy little script to help them so I thought I’d share it with everyone.

find / -path '/vmfs/*' -prune -o -size +10240000c -exec du -h {} \;

This searches the ESX ignoring the VMFS file system. For standard Linux you can put whatever you want in place of VMFS and it will ignore that folder.

Categories: Linux, VMware Tags:

VMWorld 2008

March 9th, 2008 No comments

VMWorldI am back from presenting in VMWorld 2008 in Cannes. Really enjoyed the experience of presenting to around 300 people and as my presentation was around an hour long I managed to get a lot of time to walk around. Also had so much time as I somehow managed to avoid working in the “Genius Bar” because of an error with timetabling. I haven’t been to a VMworld in the States but I heard this one was less “showbiz” than the American ones.

A lot of the presentations were very good (and some were woeful) and some of the stands there had some interesting stuff. However there wasn’t much free stuff being handed out.

The only drawback I had was that I was presenting on the last day so couldn’t really go mad in the evening. Although there were plenty of parties with free drink. Also my camera battery died on the first day and I had no charger with me! Anyway I’ll upload my pictures (and my presentation for thoes who might be interested “Advanced HA Troubleshooting”) tomorrow.

Also a recording of my presentation should be available on the VMWorld website tomorrow.

Categories: Linux, VMware Tags: