Thursday, August 6, 2009

Installing VMWare tools in Ubuntu 8.x

Ok, for Window Geeks, this is a situation when Techbytes. Let's face it, a whole lot of Windows guys can't even use the Command line well. That is because we have become so groomed on the GUI, we forget that we also need to get under the hood once in a while. This is no more clear to me teaching tech classes. Hardly anybody in the class knew how to use the command line.

Ok, also the Internet is great for help, but Linux gurus forget that some Linux commands are foreign to Window geeks. This is no more frustrating than when we want to install the VMWare tools in Ubuntu. I love this distro; but I always forget how to get the tools installed. In Windows it is pretty much a cinch. It is easy in Linux Ubuntu also, as long as you know the steps.

1. Start Ubuntu, go to the Applications Menu, Accessories, and start Terminal
2. Type this command: sudo apt-get install build-essential
3. Enter uname -r It will return a string like 2.6.27-14-generic
4. Enter sudo apt-get install linux-headers-2.6.27.14-generic
5. After it finished installing, got to the VM Menu, and Install/VMWare tools
6. This will mount the CD Drive you will see it on your desktop. Open it and Extract the vmwaretools-x.x.x-xxx.tar.gz to your desktop
7. Go back to the terminal, and change to your desktop cd Desktop
8. Change to the vmware-tools-distrib folder: cd vmware-tools-distrib
9. Run sudo ./vmware-install.pl Hit the ENTER key to take all defaults. Don't change anything.

That is it.

Delco

Tuesday, August 4, 2009

Youtube videos to mp4

Here is a Techbyte. I have been teaching classes at a local Technical Institute, and I needed to show some Youtube videos about certain topics. But the Institute locks down the Internet in the classroom - go figure, anyway, I needed to figure it out. I found this site: KeepVid to be the answer for me.

Very simple:

1. Find the Youtube video.
2. Copy the URL
3. Go to the site and put the URL in the URL field just below their banner and click the download button.
4. Look where it says "Links found" under "Download Links" Green banner.
5. If found, then just click the format you want to download it.

One thing I found is that a lot of the videos are poor in resolution, but that is the nature of a lot of the videos I have been getting. They just don't scale well in a bigger screen. But, they work for my purpose.

Delco

Monday, August 3, 2009

Enable SSH on VMWare ESXi

How do you enable SSH on ESXi so you can Putty over to it using SSH?

1. At the actual server (you need keyboard and monitor of course). Alt + F1

2. You will see black screen: Type: unsupported {ENTER} [Now you will not see anything being typed on the screen!] --- Also, one occasion, I must of messed up, because I had to reboot before this would work --- no idea why, but it should work the first time for you.

3. Now, put in the "root" username.

4. Put in "root's" password.

5. Here comes the scary part for us Window users - You have to use Vi!

6. Type vi /etc/inetd.conf --- This should open the inetd.conf file. Note: "#" means a line that is commented out.

7. Using arrow keys, find the line that starts has #ssh

8. Remove the "#" by putting cursor on it and pressing "x" key.

9. Hit the ESC key to allow you to be vi command mode.

10. Type :wq to save and exit.

11. Type ps | grep inetd

12 Look at the process ID. This is like going to Task Manager in Windows.

13. Type kill -HUP [Remember Linux is case sensitive]. This is like ending a task in Window's Task Manager.

14. Go back to Putty and now you should be able to SSH over to it.

Delco

How to open a pre-created Virtual Machine is VMWWARE ESXi

Virtual appliances are cool. They are pre-configured virtual machines you can import in ESXi and then start them up. But I found a Virtual Machine that was not created with the ability to use the import function. In other words it has the Virtual Disk and the Configuration file. In VMWare Server all you have to do is go to File, then Open, and point it to the virtual machine; but in ESXi you don't have the ability.

Now I don't know if there are other ways, but this is the way I found worked for me. First I tried creating a virtual machine the traditional way, and then copying the files over the top. That did not work, and then when you went to delete the machined of the disk, it did not get rid of all the files. Now keep in mind that I am using Veeam FastSCP to move and copy files. One thing also to note, is that while you can copy files into a folder created by ESXi ViClient, you cannot delete or create the folders themselves because of Linux folder security I assume.

OK, so let's recap the situation and my solution:

1. Wanted to play around with Openfiler - downloaded a VMWare pre-configured machine. Now they have ISO to install on "bare metal", but I don't have a lot of "bare metal" laying around. So I just wanted to look at it with it installed in a virtual machine.

2. After downloading and extracting the gz then the tar. It left me with a folder and the three necessary VMWare files for the virtual machine. I wanted put these in the ESXi server.

3. Problem: How do I do that? Copy them over yes with Veeam.

4. Second Problem: You have to create a directory like I said above but you cannot do this with Veeam. At least not with the default Linux rights set on the vmfs folder.

5. Third Problem: ESXi has no "console" like ESX.

Solution:

1 Enable SSH on ESXi.

2. After being able to Putty in to the console, create a folder with the exact name as the folder I am trying to copy over.

3. Using Veeam, copy files over into it.

4. In the ViClient, go to Summary, Data store, and browse the data store. Find the configuration file, and select "Add to inventory"

5. The machine will be added and now you can boot it up!

Voila! My solution to the problem. Got another? Let me know.

Delco

Setting up Microsoft FTP Correctly

For years I have shied away from using Microsoft FTP on a IIS server because I felt that it was not secure enough, well folks, there was one thing I did not know, and really, it was not for lack of searching. If Microsoft had a good article on it, then I did not find it. That was a real BYTE!

Here is what I knew virtualDirectory = user's name, so that always worked for me; but since you had to give "list" rights to all in the FTP site (this is because I only used one IP address [if you can give one IP to each FTP site then it is not an issue, but who can do that?], then a user could always go up to the root, and see all the virtual directories for every body else. I showed this to an ISP who really did not know about this. To my knowledge they never fixed it. Big, big problem.

1. User has account on the server like: usera, userb, userc

2. Domains, each with their own folder, and they have rights on each of their folders set with NTFS permissions:

useradomain.com = c:\domains\usera-domainname
userbdomain.com = c:\domains\userb-domainname
usercdomein.com = c:\domains\userc-domainname

3. You then set up a new virtual directory for each user under the FTP site naming the virtual directory with the same name as the "username", and of course point them to the actual directory.

4. Here is the key I did not know: It seems like the whole key is to set the "Default" directory to go nowhere. What I mean is, create a folder somewhere on the drive, call it "deadend", "blackhole", "abyss", or whatever, and give everyone "list" rights. Point the "Default" folder for the FTP site to it. That is it.

So now I have multiple domains, each with a separate user loging-in to upload their web files, and none of them can "escape" back to top and see the rest of the domains. Pretty cool. Fairly secure, and all with the built in stuff and not having to use separate FTP software - Next on my list as far as FTP - Microsoft Secure FTP - what a concept!

The best article I found on it explaining that last piece of the puzzle for me, is here. Thanks for the article guys. I really appreciate it and love sending some of my readers over to you. Keep up the good work so we can Byte back at Technology.

Delco

Delco