I am in a bit of a sticky situation. I started my current job a few months ago, and I have a web application running on an apache web server (a simple PHP-based one). I need to update this code to fix some problems in the application, and I'd like to get the code into a proper source code environment (IE. Version Control).
Skipping explanation of irrelevant details, I need to retrieve a directory (folder) from an Ubuntu Server 14.04 (CLI) Virtual Machine without adding or removing any software or other files to the machine. Currently the machine has no FTP or SCP server on it, so I cannot use those. And it's missing the /sbin/mount.nfs helper program to allow the mounting of an NFS share (we have a series of shared folders here that I could potentially use to retrieve the files if I could mount an NFS share).
Currently I only have one idea, which is to insert a USB Flash Drive into the ESXi host that is running the machine, and copying the files to that. However, the machine doesn't have a USB controller, and because it is a production machine I cannot shut it down during the workday to install one, so I'll only be able to do this after business hours. Because of this, (TLDR:) I was wondering if anyone else had any other ideas on how to retrieve a directory from a Ubuntu Server 14.04 VM without FTP, SCP, Mounting an NFS Share, or installing any new files or software.
Edit: Didn't expect all the great responses. Removing my accepted answer for now. I'll assign it elsewhere when I have a good chance to go through these responses and experiment.
Best Answer
As well as saying all the things it doesn't have, what about saying the things it does have? How big is the folder and how much free disk space is there?
Assuming you have no access to the CLI at all, even from the console:
Even though you don't have SSH access, assuming you have some kind of access to type commands and manage the server via the VM console:
Does it have FTP client installed? FTP from the server to somewhere else and upload the files.
POST
them to a remote web server uploadDoes it have netcat (
nc
) installed? You can pipetar | nc
and stream the data to a socket, and usenc | tar
on another computer on the network to receive. example