Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »

A virtual machine is software that runs an operating system within a computer. For MRI analyses, we run Linux software on a windows computer. We install the virtual machine software (VMware), and that software runs Linux.

Note: For text files to be used in Linux, open as "t" to avoid the DOS double-charater CR+LF at the end of each line (CR = carriage return /r, LF = line feed /n). (http://www.mathworks.com/support/solutions/en/data/1-15HVX/index.html?product=SL&solution=1-15HVX link]
e.g., id = fopen(newfile.bat,'wt+');
The Linux command dos2unix will remove CR characters.

See bottom of page for updating.

class=heading>Setting up Windows

VMware

#Get and install "VMware Player" (free)#Enable "Virtualization Technology"#In the BIOS, you must make sure the option to run "Intel Vistualization Technology" (or similar in AMD) is enabled; here are some instructions:www.microsoft.com/windows/virtual-pc/support/configure-bios.aspx Microsoft Virtual PC pageYou will also need a 64-bit machine running 64-bit Windows.

Virtual Machine

Get the copy of the virtual machine (VM) you will use (or create your own using "VMware Workstation"). You will need the MRI software, the account name and password, and sshd service. There is a copy ("clone") on the Share drive:
LinuxCloneVM

Copy this to a local folder; I suggest C:\LinuxVM.

Download and install VMware Player (free)

Open VMware Player, and open the saved VM; select the copy option.

To test:
Start ("Play") the virtual machine
In the Centos 6 version (as of October 2013), the password is "data" (there is only one user, which you click). In the old Centos 5 version, the usual username/password is Paul/kokako
You'll usually need to start a terminal (see icon on top toolbar).
Type FSL to get FSL

Setting up the connection

1-A. VMware settings (Player)

The network settings are already set in the copy of the VM, so all you need to do is look for the Subnet address. Go to the "Network and Sharing Center" in Control Panel, and click on the "VMnet1" connection, then click details, to find the Subnet Address (see snapshot):

Uploaded Image

1-B. VMware settings (WorkStation)This section NOT needed if you are using VMware Player'

Start by turning the VM off (under the "System" menu, select "Shut Down")

Set the network connection to Host to Host: in VMplayer, Edit Settings, Virtual Network Editor, VMnet1.
Select "Host-only" option, turn off "Use local DHCP service"
Make a note of the Subnet Address of VMnet1 (e.g., 192.168.65.0) and subnet mask (usually 255.255.255.0)

Note: I had to turn off the VNnet8, in Sep 2013 (Centos 6 and Workstation 10).

Under the VM Settings, select Network Adapter, select Connected + Connected at power on", "Host-only".

Uploaded Image

Video: Setting Linux Network Parameters (* Does not work in Internet Explorer)


***MISSING IMAGE***


2. Linux Settings

Start Linux - "play" or "resume" virtual machine
Log on (username is Paul)
In the Linux window, System => Administration => Network (you'll need to enter the password again, same as for Paul)
Select "eth0" in the Devices list, Edit
Set the IP address to be 100 on the subnet (e.g., 192.168.65.100), and set the subnet mask, and the "Default gateway address" will be the subnet address with a 1 at the end (example below).
Click "Activate"
Uploaded Image

Troubleshooting Linux Settings

Sometimes after an upgrade, there are changes to the network settings. 

sshd
To stop the slow SSH login, edit /etc/ssh/sshd_config (open a terminal, "su" to log on as super-user same password, cd to /etc/ssh, "gedit sshd_config) and add a like "UseDNS no, and make sure there are no DNS servers

Uploaded Image

3. Windows (matlab) settings

Install "PuTTY" - Google it and choose the Windows installer.
After installing, run once and connect to the IP address of the Linux VM; say Yes to add the certificate to the cache.
If you get a timeout error, start a Command Prompt and ping the IP address
e.g., C:\Users\Paul>ping 192.168.65.100
If you don't get a connection, re-check the above settings (and make sure you "Activate" the changes in the Network Configuration).

Run CSPM, Options, Local settings, and enter the IP address and the username and password of the Linux user; do Ping, and "Test Send-Command".

Shared folder

Choose a shared folder; I use one on the network, but something simple is good (e.g., "V:\LinuxShare\"). Avoid spaces in any Linux path.

Edit the VM settings, choose the Options tab, Shared Folders
Always enabled
"Add..." the folder

This will now show up in Linux (at least in CentOS) under /mnt/hgfs.

In Windows, change the folder permissions so that all users can modify, read and write.


Updating

To update:

  1. Change the VM's network settings to bridged
  2. Start/restart the VM
  3. Under System, Administration, Network, "Edit" the eth0 device and set to DHCP instead of static address
  4. Under System, Administration, Server Settings, Services, go to Network and restart
  5. To Add or Remove, go to Applications, Add/Remove Software
  6. To Update, go to Applications, System Tools, Software Updater
  7. Change back to static IP (System, Administration, Network, "Edit" the eth0 device)
  8. Change the VM settings back to Host-Only, restart
  • No labels

0 Comments

You are not logged in. Any changes you make will be marked as anonymous. You may want to Log In if you already have an account.