Odoo Help


How to drop database from terminal.

on 9/5/13, 3:32 AM 16,713 views

How to drop database from ubuntu terminal.?.


Daniel Reis

--Daniel Reis--
| 7 8 9
Linda-a-Velha, Portugal
--Daniel Reis--

Author of the "Odoo Development Essentials" book.

Applications Manager at Securitas Portugal

Github: https://github.com/dreispt

Twitter; @reis_pt

Daniel Reis
On 9/5/13, 6:30 AM
sudo -u postgres dropdb <name>


  • sudo -u postgres: run the next command impersonating the postgres user
  • dropdb <name>: command to drop a PosgreSQL database

What if there is a space character in the database name?

Gilles Lehoux
on 2/17/14, 2:43 PM
On 9/5/13, 5:23 AM

You not just drop it from the webclient. Log in as administrator and drop using master password. Althernatively log into the pgAdmin III (PostgreSQL) and drop it from there. You will need admin access to in both scenarios

yes,kaynis absolutely correct, but if we wish to drop it from the terminal itself, what we have to do?

Abhishek H Menon
on 9/9/13, 10:32 AM
Abhishek H Menon
On 9/9/13, 10:31 AM

open your terminal. type the command "dropdb database_name". Using this command you can drop your database

franklin doss
On 3/15/18, 10:53 PM

when applied dropdb datname , but " \l "  command shows deleted datname in database list.

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

3 follower(s)


Asked: 9/5/13, 3:32 AM
Seen: 16713 times
Last updated: 3/15/18, 10:53 PM