VMware – Cannot Cut, Copy, or Paste to VM’s

KB ID 0000515

Problem

Ever since ESX 4.1 this feature has been disabled and you have been unable to paste to VM, VMware say in their own documentation:

Source (Page 215 – ESX Configuration Guide ESX 4.1 vCenter Server 4.1).

To turn this feature back ON you have a few choices.

Please be aware: We are talking about copy and pasting TEXT to and from a guest VM NOT files and folders.

Solution

ESX Option 1 (Enable Copy and Paste to VM an individual Guest machine)

Using vSphere 8 or Above

Firstly, you need to shut the virtual machine down > Right Click it > Edit Settings >  Advanced > Add the following TWO attributes and values.

Add in the following two;
Attribute: isolation.tools.copy.disable, Value: false
Attribute: isolation.tools.paste.disable, Value: false

Click OK >  Power the VM back on.

Using HML5 Web Client (Enable Copy and Paste to VM)

Firstly, you need to shut the virtual machine down > Right Click it > Edit Settings > VM Options > Advanced  > Scroll down.

 

Edit configuration > Add configuration params;

Add in the following two parameters then click OK

Name: isolation.tools.copy.disable, Value: false
Name: isolation.tools.paste.disable, Value: false

Using Flash Web Client.

Firstly, you need to shut the virtual machine down > Right Click it > Edit Settings > VMware Option Tab > Advanced > Edit configuration > Add in the following;

Name: isolation.tools.copy.disable, Value: false
Name: isolation.tools.paste.disable, Value: false

 

OK > OK > Power on VM

Using VMware Client (Enable Copy and Paste to VM)

1. Firstly, you need to shut the virtual machine down > Right Click it > Edit Settings > Option Tab > Advanced > General > Configuration Parameters.

2. Select “Add Row” and add the following two options:

[box]isolation.tools.copy.disable

isolation.tools.paste.disable [/box]

Set both these values to FALSE > OK > OK > Power the VM back on again.

Note: Even without these values set, if a VM is vMotioned to an ESX host that has the copy.paste options set in it’s config file (see below) then these features are automatically enabled.

Option 2 (Enable Copy and Paste to VM on an individual Guest machine)

1. You can also achieve the same as above by directly editing the .vmx file for the virtual machine, Add the following two values as shown below:

[box]isolation.tools.copy.disable=”FALSE”

isolation.tools.paste.disable=”FALSE” [/box]

Note: Even without these values set, if a VM is vMotioned to an ESX host that has the copy.paste options set in it’s config file (see below) then these features are automatically enabled.

Option 3 (Enable Copy and Paste on the ESX host for all the VM’s on that host)

Note: This procedure will be removed/reset after an ESX upgrade. (You will need to carry out this procedure again post upgrade).

1. Connect to your ESX server, either directly on the console, or via SSH. and execute the following command:

[box]vi /etc/vmware/config[/box]

 

2. Press i to insert text and paste in the following two lines:

[box]isolation.tools.copy.disable=”FALSE”

isolation.tools.paste.disable=”FALSE” [/box]

Press Escape > then type :wq to save the changes.

Additional Steps for Linux / Ubuntu to allow Copy and Paste to VM

1. Assuming you have the VMware tools installed in your Linux guest VM, if not execute the following command:

[box]sudo apt-get install open-vm-toolbox[/box]

To enable copy paste on the guest execute the following command:

[box]vmware-toolbox &[/box]

One the VMware tools properties page pops up you will be able to copy and paste.

Enabling Copy and Paste in VMware Workstation

Out of the box, this functionality is switched on. However if you lose it then open the virtual machines settings > Options tab > Guest Isolation > Enable the Copy and paste option.

Related Articles, References, Credits, or External Links

NA

Using the VI Editor (For Windows Types)

KB ID 0001304 

Problem

I dont have a ginger ponytail, nor do I wear sandals, couple these two things together and you will understand why I find VI so confusing! Many times I’ve had to alter a config file on an appliance, or a Linux box, and sat frowning at VI wondering why I can’t change a one to a zero.

Note: Nano is easier, if possible try nano {filename} to save hassle. But on hardened appliances for example, it wont be there. 🙁

So, this article gives you enough information to open, edit, and save a file. If you want a massive tutorial on VI you are in the wrong place.

Solution

Not really part of VI but you need to know where the file is you want to edit, and the path to it;

[box]

For Example:

vi {filename}
vi {path}/{filename}

[/box]

You can ‘move around’ the file being edited with your arrow keys.

Deleting Text: Press the X key to delete the character that’s ‘under’ the cursor.

Selecting Text: Press (and hold) the V Key while using the arrow keys to select multiple text characters.

Note: From here you can CUT (press X), or COPY (press Y). To PASTE put the cursor where you want the text and press P.

Inserting Text: To actually type anything, you need to be in ‘insert‘ mode press I then type in your text.

Note: Some flavours of Linux give no indication you are in ‘insert‘ mode, (unlike the example below).

Saving and Exiting: you need to be in ‘command‘ mode to save and exit, to enter ‘command‘ mode press ESC. As above there may be no visual clue what mode you are in. To SAVE AND EXIT type :wq {Enter}. TO EXIT Type :q {Enter}. Basically q means quit and w means ‘write’ the changes.

Job done, now keep your Linux skills quiet or you may get your dinner money stolen, and not get a girlfriend.

Related Articles, References, Credits, or External Links

NA

CentOS – Disable BIND DNS Recursion

KB ID 0000981

Problem

I got a Tweet this morning, to say the site was down.

I checked and the VPS was off-line? So I powered it on and waited a few minutes. Linux is not one of my strongest technical areas so I did some Googling about what logs to check etc. When I looked in the var/log/messages log it was full of these, up to the point where it went down;

[box] Aug 7 03:51:52 MY-HOSTNAME named[490]: error (unexpected RCODE REFUSED) resolving ‘anotherdomain.com.ru/ANY/IN’: 123.123.123.123#53 [/box]

After some more reading it became clear that I’d been used in part of a DDOS DNS amplification attack. This was possible because the DNS BIND server that I was running had DNS recursion enabled. This means that if it can’t resolve a DNS query then it attempts to resolve the DNS query for you, (currently this is the default setting). You can check yours online with this tool, (you don’t want it to say ‘open’).

Solution

Disable BIND DNS Recursion (From the Console)

1. Log onto the server directly or via SSH, navigate to, and open the named.conf file.

[box]cd /etc
vi named.conf [/box]

2. Near the top of the file locate ‘recursion yes;

3. Press ‘I’ to go into ‘insert’ mode, using the arrow keys navigate to ‘yes’ and change it to ‘no’, Press {Esc} then to save and exit type ZZ (for some reason :wq wouldn’t save on mine!).

4. Then restart BIND DNS. Check once again with the tool and hopefully now it will say ‘no response’

[box] service named restart[/box]

Disable BIND DNS Recursion (From Webmin)

1. Log into Webmin > Servers > DNS BIND Server > Edit Config File.

2. Change ‘recursion yes;‘ to ‘recursion no;‘ > Save.

3. In the top right hand corner click ‘Stop BIND’ then ‘Start BIND’.

Related Articles, References, Credits, or External Links

NA

 

CentOS 7 – No Network Connection

KB ID 0001047 

Problem

A while ago I spun up a CentOS server in VMware Workstation, and I could not get it connected to the network, I was in a bit of a hurry, so I blew it away and just built a new server with CentOS 6. This week I’ve been using VirtualBox and spun up a new CentOS 7 server and had the same problem.

Solution

1. Quite why CentOS 7 does this I’m not sure, My NIC is called enp0s3 (run ‘ip addr’ to find yours). Then take a look at;

[box]cat/etc/sysconf/network-scripts/{interface name}[/box]

As you can see (above), the ONBOOT section is set to ‘no’.

2. Use the VI editor (because you wont have Nano installed yet) to edit the file (Press I to insert > Edit the file > Escape > :wq {Enter}).

3. Reboot the server, and now we have comms!

 

Related Articles, References, Credits, or External Links

NA