How do I start the postgreSQL service upon boot?
        Posted  
        
            by 
                Homunculus Reticulli
            
        on Ask Ubuntu
        
        See other posts from Ask Ubuntu
        
            or by Homunculus Reticulli
        
        
        
        Published on 2012-06-21T18:08:59Z
        Indexed on 
            2012/06/21
            21:23 UTC
        
        
        Read the original article
        Hit count: 370
        
I am running PostgreSQL (v 8.4) on Ubuntu 10.0.4.
The PG service currently starts on reboot (after I installed PG on my machine), however, I want the service to use a new data directory.
Currently, after a reboot, I have to:
- Stop the currently running PG service
- manually type: /usr/local/pgsql/bin/pg_ctl start -D /my/preffered/data/directory -l /usr/local/pgsql/data/logfile
Which file do I need to edit to ensure that I always have the service using the correct data folder?
© Ask Ubuntu or respective owner