I am AIX Administrator and fresher in Python. I have installed new python version on my AIX test server. i want to write a program in python which help me to transfer data from one server to other server without any third party tool.
i found one link which help us to read and write data in perl. (docstore.mik.ua/orelly/perl/cookbook/ch16_05.htm. But when I tried it in python, then it is not working properly.
Here my idea is whenever my system will start mksysb backup (System backup) through python program (I wrote command in my program which is working properly), But i want to transfer data at the same time to other system through PIPE device in python.
Is it really possible?
could you please give me some idea. I didnot write any code to transfer data through PIPE. Because I really dont know how it works. on net i got many sites which tells chatting related program which is not helpful for me.
i have one perl program, which uses fork & named pipe,
on the host, parent fork: using SSH, backup command writes stream data directly to a pipe device (created by mknod) & child fork: reads the pipe device using cat & redirects data to a file.
Here is some part of my program.
my %pid;
if ( ( $pid{write} = fork()) == 0 ) {
print “*** starting system backup “;
print “DEBUG: $ssh $host ‘sudo $sys_backup $pipe 2>&1’\n” if $debug>0;
exec(”$ssh $host ‘sudo $sys_backup $pipe 2>&1’”);
exit;