Using dd


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Using dd
# 1  
Old 03-22-2011
Using dd

hi i was executing a program which had following commands
Code:
command = "mkdir /var/log/TC"
                username = ""
                ipAddress = ""
                hi1=executeSshCommand(username, ipAddress, command, password=None)
                print hi1
        command = "touch /var/log/TC/huge.txt"        
        hi2=executeSshCommand(username, ipAddress, command, password=None)
        print hi2
        command = "dd if=/dev/zero of=/var/log/TC/huge."
        hi3=executeSshCommand(username, ipAddress, command, password=None)
        print hi3

what will be the value of hi3?
and if i want to pass any command after this ,do i need to wait (as it takes time to fill zeros)
or if i give any next command will it execute only after the execution of dd command?

Thanks

Last edited by Scott; 03-22-2011 at 03:58 AM.. Reason: Code tags, please...
# 2  
Old 03-22-2011
I'm not sure about your script. How ever the as far as I know the commands in a script are executed in order and hence commands after dd will wait till it finishes.
# 3  
Old 03-22-2011
What computer language is this script written in? The syntax on most of the lines is not a Bourne-type Shell.
Login or Register to Ask a Question

Previous Thread | Next Thread
Login or Register to Ask a Question