• Facebook
  • Twitter
  • Reddit
  • StumbleUpon
  • Digg
  • email

All Samples(3193)  |  Call(3065)  |  Derive(0)  |  Import(128)
getpid() -> pid

Return the current process id

src/p/e/pexpect-HEAD/pexpect/examples/bd_serv.py   pexpect(Download)
        daemonize()
        #daemonize('/dev/null','/tmp/daemon.log','/tmp/daemon.log')
 
    sys.stdout.write ('server started with pid %d\n' % os.getpid() )
 
    virtual_screen = ANSI.ANSI (24,80) 
    child = pxssh.pxssh()

src/p/y/python-cookbook-HEAD/cb2_examples/cb2_9_13_sol_1.py   python-cookbook(Download)
def _example_main ():
    ''' Example main function: print a count & timestamp each second '''
    import time
    sys.stdout.write('Daemon started with pid %d\n' % os.getpid() )
    sys.stdout.write('Daemon stdout output\n')
    sys.stderr.write('Daemon stderr output\n')
    c = 0

src/p/e/pexpect-2.4/examples/bd_serv.py   pexpect(Download)
        daemonize()
        #daemonize('/dev/null','/tmp/daemon.log','/tmp/daemon.log')
 
    sys.stdout.write ('server started with pid %d\n' % os.getpid() )
 
    virtual_screen = ANSI.ANSI (24,80) 
    child = pxssh.pxssh()

src/p/y/pyke-HEAD/examples/web_framework/preforked_server.py   pyke(Download)
def kill(pids, signum, frame):
    sys.stderr.write("preforked_server(%d) caught SIGINT\n" % os.getpid())
    sys.stderr.write("preforked_server(%d) self.pids is %s\n" %
                     (os.getpid(), str(pids)))
    for pid in pids: os.kill(pid, signal.SIGTERM)
    sys.exit(1)
 

src/c/e/cerebrum-HEAD/trunk/cerebrum/clients/examples/bofh.py   cerebrum(Download)
        self.__max_timeout = max_timeout
        self.__warn_delay = warn_delay
        self.__timer_wait = None
        self.my_pid = os.getpid()
        self.__quit = False
 
    def __got_alarm(self, *args):

src/p/y/py2app-0.5.2/examples/embedded_interpreter/simple/hello.py   py2app(Download)
def host_main():
    print 'Hello from main executable (pid: %s)' % (os.getpid(),)
    print_sys()
    print ''
    os.spawnv(os.P_WAIT, sys.executable, [sys.executable, __file__, 'subinterpreter', repr(sys.path)])
 
def spawned_main():
    print 'Hello from spawned executable (pid: %s)' % (os.getpid(),)

src/c/e/cerebrum-HEAD/cerebrum/clients/examples/bofh.py   cerebrum(Download)
        self.__max_timeout = max_timeout
        self.__warn_delay = warn_delay
        self.__timer_wait = None
        self.my_pid = os.getpid()
        self.__quit = False
 
    def __got_alarm(self, *args):

src/c/y/cycad-HEAD/trunk/src/pexpect-2.0/examples/bd_serv.py   cycad(Download)
    #daemonize ()
    #daemonize('/dev/null','/tmp/daemon.log','/tmp/daemon.log')
 
    sys.stdout.write ('Daemon started with pid %d\n' % os.getpid() )
 
    vs = ANSI.ANSI (24,80)
    p = pexpect.spawn ('ssh %(USER)s@localhost'%locals(), timeout=3)

src/c/y/cycad-HEAD/src/pexpect-2.0/examples/bd_serv.py   cycad(Download)
    #daemonize ()
    #daemonize('/dev/null','/tmp/daemon.log','/tmp/daemon.log')
 
    sys.stdout.write ('Daemon started with pid %d\n' % os.getpid() )
 
    vs = ANSI.ANSI (24,80)
    p = pexpect.spawn ('ssh %(USER)s@localhost'%locals(), timeout=3)

src/p/e/pexpect-HEAD/pexpect/examples/rippy.py   pexpect(Download)
__revision__ = '$Revision: 11 $'
__all__ = ['main', __version__, __revision__]
 
GLOBAL_LOGFILE_NAME = "rippy_%d.log" % os.getpid()
GLOBAL_LOGFILE = open (GLOBAL_LOGFILE_NAME, "wb")
 
###############################################################################

  1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9  Next