Thanks! fs-utils seems exactly what I was looking for... I got some link error (like below) when compiling fs_utils, but the Makefile gave me enough information to write a small example which seems working.
/home/lsun/workspace/gitrepo/rump/rumpctrl/rumpdyn/lib/librumpkern_sys_linux.so: undefined reference to `rumpns_compat_50_sys_settimeofday' On Tue, Jun 2, 2015 at 3:36 PM, Antti Kantee <[email protected]> wrote: > [generally speaking, if you want to start discussing another subject, > please start another thread] > > On 02/06/15 19:03, Liming Sun wrote: > >> I guess this question might have been discussed... is it possible to call >> regular libc functions and rump APIs (such as rump_sys_XXXX) in the same C >> file? >> > > If you are running in host namespace, yes. If you are running in full > rump kernel namespace, no. For examples of the former, see > buildrump.sh/tests. For examples of the latter, see rumprun. > > For example, is there an easy way to implement a 'cp' command to copy >> between Linux host FS and the rump FS ? >> > > That's a very multifaceted question. You can use e.g. rumpctrl/dd to move > single files against live rump servers or the fsu_ecp command from fs-utils > against cold images. fs-utils doesn't not currently work against live > servers, but in theory it would not be a big task to adjust it to work that > way. (fs-utils is also a good example of how to call both host syscalls > and rump kernel syscalls in the same program) > >
