- Odoo 11 Development Essentials(Third Edition)
- Daniel Reis
- 426字
- 2021-08-27 19:32:38
Initializing a new Odoo database
To create and initialize an Odoo database with the Odoo data schema, we should run the Odoo server using the -d option:
$ ~/odoo-dev/odoo/odoo-bin -d testdb
This will take a couple of minutes to initialize the testdb database, and it will end with an INFO log message, Modules loaded. Note that it might not be the last log message, and it can be in the last three or four lines. With this, the server will be ready to listen to client requests.
By default, this will initialize the database with demonstration data, which is often useful for development databases. This is the equivalent to having the Load demonstration data checkbox ticked when creating a new database from the user interface.
To initialize a database without demonstration data, add the --without-demo=all option to the command.
To be able to create a new database, your user must be a PostgreSQL superuser. The PostgreSQL setup script used in the previous section takes care of that. Just in case you also need it for some other user, this is the command to make the current Unix user a PostgreSQL superuser:
$ sudo createuser --superuser $(whoami)
Now that we have a running Odoo instance, we can access it by opening the http://<server-name>:8069 URL with a web browser. This should present us with the Odoo login screen. If you don't know your server name, type the hostname command in the terminal in order to find it or the ifconfig command to find the IP address.
The default administrator account is admin, with its password admin. Upon login, you are presented with the Apps menu, displaying the available applications.
To stop the Odoo server instance and return to the command line, press Ctrl + C at the terminal window running the server. Pressing the up arrow key will bring us the previous shell command, so it's a quick way to start Odoo again with the same options. The Ctrl + C keys followed by the up arrow key and Enter is a frequently used combination to restart the Odoo server during development.
- Excel從小白到小能手
- Word Excel PPT商務辦公從新手到高手(白金全彩版)
- Excel大神是怎么做表的
- MATLAB R2020a完全自學一本通
- Office 2016從新手到高手
- 和秋葉一起學:秒懂Word(全彩版)
- Excel 2013從新手到高手(超值版)
- Word綜合應用簡明教程
- Office 2003辦公軟件實用教程
- Word/Excel/PowerPoint 2013三合一辦公應用
- Excel數據透視表應用之道(雙色板)
- Word Excel PPT 2013:辦公應用從入門到精通
- Excel 2013操作與技巧
- Java語言程序設計教程
- Word/Excel/PowerPoint 2007三合一辦公應用實戰從入門到精通