Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to simulate user activity on a virtual machine in a completely automated maner. That is, I would like to run a program or a set of scripts that would simulate an user using a computer for an indefinite amount of time (say, simulate an office worker - write some random files, open some files, check webpages, etc.)

Basically, I'm simulating an internal network over a set of virtual machines and would like to add some activity to the network to make it more realistic.

Is there a program or a set of scripts out there that could do the described job?

I was thinking that network testing tools might be of help, but would a set of those be enough to simulate activity on different aplications (say, mail servers, ldap server, nfs, apache, etc.) ?

Any advice on how to acomplish this?

Thank you

share|improve this question
See also unix.stackexchange.com/questions/11296/… for automating web traffic (client-side). – Gilles Feb 28 '13 at 14:15

You could use the expect tool to run programs in the VM. expect is a program that uses Tcl as it's scripting language, and extends the language a bit. It's been a long while since I've used expect, but I recall it being a bit inobvious as far as how to get some things to happen. It did have the capability of randomly spacing the timing of "typing" done by a simulated human, so it may be just what you want.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.