Monday, 19 September 2011

How to Auto Mount Partitions at Linux Startup the Easy Way

Usually making Ubuntu mount a partition at startup would require fiddling with the “fstab” which is confusing. The easiest way to mount your partitions automatically when you turn on your computer is by reading this article. So let’s get started!

We are going to install the program that will make the process easy is called “Storage Device Manager”. Enter this command in a terminal window to install it:
sudo apt-get install pysdm
Or search for it in Ubuntu Software Center
Now fire it up from System > Administration > Storage Device Manager. Once running, from the left hand side panel choose the partition you want to be mounted on startup (expand the hard drives list first). Then click on “Assistant” on the right side.
Now you are presented with the options window. Just check the “The file system is mounted at boot time” and uncheck the “Mount file system in read-only mode”.
You can edit the other options if you want but be careful, it might damage your system. When done click the “OK” button then hit “Apply”. Close the program and restart to see the effect. That’s it!

Mount USB Devices in Virtualbox with Ubuntu

Mounting a USB device inside a virtual machine is often a tool that you cannot go without. If you are using Virtualbox in Ubuntu however, you need to take a few extra steps to make it work.

Install Virtualbox

The first thing you need to do is install Virtualbox from Oracle’s website. It is different than Virtualbox OSE which is included in the Ubuntu repositories because the Virtualbox from Oracle includes proprietary software which allows you to mount USB devices inside you VM among other things. If you already have Virtualbox OSE installed from the Ubuntu repositories, uninstall it before installing the .deb file from Oracle’s website.
Note: Any VMs you made with Virtualbox OSE will still work with the standard version of Virtualbox. Uninstall Virtualbox OSE before installing virtualbox from Oracle.

Set up Your Virtual Machine

Install your virtual machine and once the installation is complete install the Virtualbox guest additions into the guest OS from the devices menu.
Turn the virtual machine off and go to the settings for the VM. Click on USB on the left and check the top two boxes in the window shown.
Along the right hand side there will be a few icons to set up USB filters. These filters are where you can tell Virtualbox what USB devices you want to have available to your guest OS. Plug in your USB device and click on the second icon to view available USB devices that can be mounted into the guest OS.
Select any devices you would like to mount in the guest OS and then close out of the settings window.

Set Up Your User Account

The next thing you need to do is add your user to the vboxusers group on your system. Navigate to the System -> Administration -> Users and Groups option and click on manage groups on the left side.
Scroll down in the group settings and highlight the vboxusers group and then click properties on the right.
In most cases you probably will only have one user so check the box to include your user in the group; put in your admin password when prompted, and then restart your computer.

Mount Your USB Device

Once your computer restarts, log in and start your virtual machine. In the devices menu of the VM, select the USB device you want to mount.
Your device should show up automatically in the VM and you can use it the same way you would be able to on the host operating system.

How To Run Chrome OS in VirtualBox

Recently a build of Google’s Chrome OS was released for testing. Though it’s not ready for prime time, you might want to test it out in a virtual machine. Today we take a look at how to setup and run it in VirtualBox.
Note: In this example we are using VirtualBox 3.0.12 running on a 32-bit version of Windows 7 Ultimate.
Setup VirtualBox
The first thing to do is click on New to create a new machine in VirtualBox.
1chrome
The New Virtual Machine wizard opens where you just want to click Next.
2chrome
Type in a name for the machine and for OS Type you want to select Linux and the default version will be Ubuntu…you can leave that and click Next.
3chrome
Now you want to select the amount of memory to allocate for the machine. In our test we used 512MB which seems adequate, but you can experiment with different amounts.
4chrome
In the next step, select Use existing hard disk…
5chrome
Then add the VMDK file you downloaded to Virtual Media Manager and select it.
6chrome
You’re brought back to the wizard where the screen should look similar to this.
7chrome
Then you’re presented with the summary of the new VM and if everything looks correct click Finish.
8-chrome
Now you will see the Chrome OS in the list of your virtual machines and you can start it up.
9-chrome
The Chrome OS will start up and the first screen you’re presented with is the log on. You need to enter in your Google account name and password to begin a session.
10chrome
That is all there is to it. Now you can start playing around with the new OS from Google.
11chrome
Conclusion
For those of you who like to try out the newest technology, this is a good option for testing out the Chrome OS. At this time don’t expect a whole lot of awesomeness with this build of Chrome OS. At least you can geek out on it and see what the hype is all about. Of course you can run it in VMware Player as well, but if you’re partial to VirtualBox, this will get you going.

How to Test Drive Windows 8 in VirtualBox

2011-09-16_132044
Want to take the next generation of Windows for a free test drive? Of course you do; it’s still got that new car smell. Read on to see how you can combine the Windows 8 developer release with VirtualBox for free next-gen OS exploration.

What You’ll Need

You only need a few things for this tutorial and all of them—the price of good hardware aside!—are free and readily available. Before we get started you’ll need to do:
On the hardware side of things you’ll need a computer with a processor that supports Virtualization Technology (common on modern processors, you can check the documentation for your processor or use this Microsoft tool to check), a decent amount of memory and some spare hard drive space (we’ll be devoting 2GB of RAM and 20GB of HDD space to the our Windows 8 virtual machine). You could attempt it with lower specs, but we’d recommend against it.
We’ll also be using the 32-bit (x86) English Developer Preview. Once you’ve installed VirtualBox (or updated your current install) and you’ve downloaded the .ISO file, it’s time to proceed.

Creating and Configuring a New VirtualBox Virtual Machine for Windows 8

2011-09-16_114231
VirtualBox makes virtual machine creation easy; just make sure to follow along so you don’t miss a step. Fire up VirtualBox and navigate to Machine –> New. Click next on the new virtual machine notice window and then, as seen in the screenshot below, name your new virtual machine and select the OS type. We named ours Windows 8 Dev (to distinguish it from the future Windows 8 Beta and Final we’re bound to install) and set the OS type to Microsoft Windows / Windows 7.
2011-09-16_114327
Add caption
In the next step you’ll select the system RAM you’ll allocate to the machine. We’d recommend allocating, at minimum, 2GB of RAM. You can squeeze by with only 1GB but unless your system specs absolutely constrain you to that size you should go bigger for better performance. 2011-09-16_114609
Once you’ve selected the amount of memory you wish to allocate, you’ll be prompted to load or create a Virtual Hard Disk. The default settings are the ones we want (Boot Hard Disk and Create new hard disk selected).
2011-09-16_115117
Click Next and the Virtual Disk Wizard will launch. The first step in the wizard is to select your disk storage type. Your options are dynamic or fixed storage. We’re going to go with Fixed-size storage for two reasons—one, this is a development build and we’re not sure if it will play nice with dynamic storage and two, the fixed size ensures it won’t balloon up if anything goes wrong. 2011-09-16_115654
The Microsoft spec sheet for the Windows 8 Development Release indicates you need at least 16 GB of hard drive space. That’s a tad on the small side and we hate running low on space. Since we’re using a 500GB drive in our machine exclusively for virtual machines and software testing, we can easily allocate 30GB to play it safe. We’d recommend you set the size to 20GB at minimum. 2011-09-16_115902
After you pick the drive size, double check the summary before clicking Finish. Sit back and relax while your new Virtual Hard Drive is generated—now might be a good time for a cup of coffee.
2011-09-16_120028
When your new Virtual Hard Drive is complete, click Finish to return to the main VirtualBox interface. Now it’s time to move onto the next step, installing Windows 8 Developer Preview onto our freshly minted Virtual Hard Disk.
Installing Windows 8 Developer Preview
2011-09-16_122954
Back in the main VirtualBox window you should see the entry you created, such as Windows 8 Dev—ignore the multitude of other installations in our screenshot, we’re huge Virtualization fans.
Highlight your new Windows 8 machine and click the Settings icon (or press CTRL+S). Let’s work down the sidebar menu.
2011-09-16_123446
First stop in the System menu. Start with the Motherboard sub-menu and check Enable IO APIC to improve performance for your virtual machine. In the Processor sub-menu check Enable PAE/NX (again, to boost performance). Finally under the Acceleration sub-menu make sure both of the hardware virtualization boxes are checked—VT-x/AMD-V and Nested Paging, respectively.
Now it’s time to attach our boot disk to the virtual machine so we can install Windows 8. While still in the greater Settings menu navigate to the Storage options via the sidebar. Inside the storage menu, click on the IDE Controller\Empty entry in the Storage Tree. In the pane next to the storage tree labeled Attributes, click on the CD icon next to the CD/DVD Drive entry.
2011-09-16_124138
A context menu will pop up. The first option on that context menu is Choose a virtual CD/DVD disk file. Select that option and, when the file select box opens, navigate to and select the Windows 8 .ISO file you downloaded at the beginning of this tutorial. You should now see, instead of Empty under the IDE Controller, the name of the Windows 8 .ISO file you selected.
There are no more tweaks necessary in the Settings menu. Click OK in the lower right corner to return to the main VirtualBox interface.

Installing Windows 8

2011-09-16_125156
Back in main VirtualBox interface, click on the Windows 8 virtual machine. Quickly double check that the Windows 8 .ISO is listed under the storage options—as it is in the screenshot above—then click Start in the right-click context menu or double click the entry to launch the machine.
If everything goes right, you’ll see a sequence of boot screens, and then this blue installation screen:
2011-09-16_125518
Select the appropriate language, time, and input settings, and then click next. On the following screen click Install Now. The whole installation, now that the VirtualBox configuration is out of the way, is very straight forward. Accept the developer’s license, select Custom installation (instead of upgrade), the HDD you want to install to (the only one available, the disk you created) and you’re on your way:
2011-09-16_125958
When it finishes and reboots you’ll have a few last customizations to make (such as picking a computer name, login, and choosing to link your fresh Windows 8 install to a Windows Live account or use an off-line account. When you’re done, it’ll take a moment to finish preparing everything and then you’ll be greeted with the new Windows 8 Metro UI:
2011-09-16_131502
Congratulations! You’re running Windows 8 Developer Preview in VirtualBox. Have fun playing around and, if you discover something new, interesting, or fun, sound off in the comments so your fellow readers can discover and play with it too.

Saturday, 17 September 2011

Make Bootable Image File from Power ISO


Run PowerISO.
Click the "New" button on toolbar or choose  the "File > New > Data CD / DVD Image" menu.
Click on the "Add" button on toolbar to add files and folders. You can also directly drag files and folders from Windows Explorer to the PowerISO window.

Choose the menu "Action > New Folder" to create a new folder.
Choose the menu "Action > Change Label" to change the default label.
Choose the menu "File > Properties" to set the iso file properties.
Choose the menu "Action > Boot > Add Boot Information" to load a bootable image file.
Click on the "Save" button on toolbar, or click on the "File > Save As..." menu.
Save the bootable image file to ISO, BIN, or DAA format.

Friday, 16 September 2011

Bref info about DLL

A DLL is a Dynamic Link Library

 

In a nut shell, a dynamic link library (DLL) is a collection of small programs, which can be called upon when needed by the executable program (EXE) that is running. The DLL lets the executable communicate with a specific device such as a printer or may contain source code to do particular functions.
An example would be if the program (exe) needs to get the free space of your hard drive. It can call the DLL file that contains the function with parameters and a call function. The DLL will then tell the executable the free space. This allows the executable to be smaller in size and not have to write the function that has already exists.
This allows any program the information about the free space, without having to write all the source code and it saves space on your hard drive as well. When a DLL is used in this fashion are also known as shared files.
The advantage of DLL files is that, because they do not get loaded into random access memory (RAM) together with the main program, space is saved in RAM. When and if a DLL file is called, then it is loaded. For example, you are editing a Microsoft Word document, the printer DLL file does not need to be loaded into RAM. If you decide to print the document, then the printer DLL file is loaded and a call is made to print.
All in all a DLL is an executable file that cannot  run on its own, it can only run from inside an executable file. This would be like having a car without an engine, where as an executable has an engine.
To do load a DLLl file, an executable needs to declare the DLL function. A DLL may have many different functions in it. Then when needed the call is made with the required parameters.
Here is what a Declaration and call might look like in a executable file. This example is simplified so that you might understand it better:
  • Declare GetFreeSpacex, Kernel32.dll (Drive_Letter, Buffers_If_Any, Value_Returned) 
    Now lets run a program and make the call.
    The DLL is not loaded into RAM until the next line.
  • GetFreeSpacex "C",Buffers_If_Any, Drive_Letter
    Now let's tell the user how much free space is on drive C
  • Use a MessageBox = "The free space on drive C: is ", Value_Returned, "bytes"
This call required 3 lines of code. Where as if you did not call the DLL file it may have taken you 30 or 40 lines of code.
If a call or a declaration is made incorrectly a GPF (General Protection Fault) may occur. A call to the same DLL but of a different version might require more or less parameters; or the call may not exist. If a DLL or an executable is the wrong version for your OS (Operating System) it will cause a GPF or lockup your machine. To fix GPF errors you should use a tool like System Sentry. System Sentry can show you what calls are available in a DLL file and what Calls an executable file is making. It can also tell what version a DLL is, and track when one is replaced.
Generally newer version DLL files are backward compatiable.DLL files from Windows ME may not be compatible with Windows 98. Many Windows ME files work well on 98 but not all will. The same hold true for Windows XP and 2003. If you dual boot a computer with XP and 2003 you must use the file C:\NTLDR and C:\Ntdetect.com from Windows 2003. If you use the files from XP Windows 2003 will not boot, but XP will. NTLDR is backward compatible

Overview of the Linux file system

Overview of the Linux file system

/bin          All commands which are used by normal users
/etc          System conf files
/var          Server data logs Mail proxy cache
/dev         All devices name stored in /dev
/sbin        All commands which are used by supper user
/boot        Linux kernel ( vmlinuz , initrd ) Grub directory
/usr          All gui tools installed in /usr
/proc       System information’s ( picture of RAM )
/home     User's home dir's
/tmp        Temporary files
/media      Auto mounted devices mount point in /media
 
Browser Name:
Browser Version:
Browser Code Name:
User-Agent: