[695] | 1 | # $Id$ |
---|
| 2 | |
---|
| 3 | PyKota - Print Quota for CUPS |
---|
| 4 | |
---|
| 5 | (c) 2003 Jerome Alet <alet@librelogiciel.com> |
---|
[873] | 6 | This program is free software; you can redistribute it and/or modify |
---|
| 7 | it under the terms of the GNU General Public License as published by |
---|
| 8 | the Free Software Foundation; either version 2 of the License, or |
---|
| 9 | (at your option) any later version. |
---|
[695] | 10 | |
---|
[873] | 11 | This program is distributed in the hope that it will be useful, |
---|
| 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
| 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
| 14 | GNU General Public License for more details. |
---|
[695] | 15 | |
---|
[873] | 16 | You should have received a copy of the GNU General Public License |
---|
| 17 | along with this program; if not, write to the Free Software |
---|
| 18 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. |
---|
| 19 | |
---|
[695] | 20 | ============================================================ |
---|
| 21 | |
---|
| 22 | Documentation for the pykota-postgresql.sql script : |
---|
| 23 | ---------------------------------------------------- |
---|
| 24 | |
---|
[874] | 25 | This script is to be used to create an empty Quota Storage |
---|
| 26 | DataBase using PostgreSQL as a backend. |
---|
| 27 | |
---|
| 28 | If you have already installed PyKota, and have datas in your |
---|
| 29 | Quota Storage DataBase, you may prefer to skip this section |
---|
| 30 | and read the next one. |
---|
| 31 | |
---|
[695] | 32 | - Launch the psql frontend and connect to the |
---|
| 33 | database template1 as a PostgreSQL administrator |
---|
| 34 | (i.e. the postgres user) : |
---|
| 35 | |
---|
| 36 | $ psql -h localhost -U postgres template1 |
---|
| 37 | |
---|
| 38 | - Executes the pykota-postgresql.sql script : |
---|
| 39 | |
---|
| 40 | template1=# \i pykota-postgresql.sql |
---|
| 41 | |
---|
| 42 | - Quit the psql frontend : |
---|
| 43 | |
---|
| 44 | template1=# \q |
---|
| 45 | |
---|
| 46 | - Your PostgreSQL PyKota storage is now ready |
---|
| 47 | for use. |
---|
| 48 | |
---|
| 49 | ============================================================ |
---|
[874] | 50 | |
---|
| 51 | Upgrade script : |
---|
| 52 | |
---|
| 53 | An sql script to upgrade a pre-1.01 PyKota Quota Storage |
---|
| 54 | DataBase is included, if you want to keep your datas from |
---|
[880] | 55 | a pre-1.01 PyKota version, then please launch the following |
---|
| 56 | commands : |
---|
[874] | 57 | |
---|
[880] | 58 | - Launch the psql frontend and connect to the |
---|
| 59 | database pykota as a PostgreSQL administrator |
---|
| 60 | (i.e. the postgres user) : |
---|
| 61 | |
---|
| 62 | $ psql -h localhost -U postgres pykota |
---|
| 63 | |
---|
| 64 | - Executes the pykota-upgrade-postgresql.sql script : |
---|
| 65 | |
---|
| 66 | pykota=# \i pykota-upgrade-postgresql.sql |
---|
| 67 | |
---|
| 68 | - Quit the psql frontend : |
---|
| 69 | |
---|
| 70 | pykota=# \q |
---|
| 71 | |
---|
| 72 | - Your PostgreSQL PyKota storage is now ready |
---|
| 73 | for use. |
---|
| 74 | |
---|
[874] | 75 | If you already run PyKota v1.01 or above, you don't need |
---|
| 76 | to run this upgrade script. |
---|
| 77 | |
---|
[880] | 78 | WARNING : |
---|
| 79 | |
---|
| 80 | This script requires a recent version of PostgreSQL to run |
---|
| 81 | successfully, because it requires the ALTER TABLE DROP COLUMN |
---|
| 82 | syntax to be supported. However in case you've got an older |
---|
| 83 | version, upgrading PostgreSQL is not mandatory, you will just |
---|
| 84 | have two unused fields in the grouppquota table, these |
---|
| 85 | fields are pagecounter and lifepagecounter, just forgot them. |
---|
| 86 | |
---|
[874] | 87 | IMPORTANT : |
---|
| 88 | |
---|
| 89 | Because the modifications are just about Group Print Quotas |
---|
| 90 | and because Group Print Quotas are currently not fully |
---|
| 91 | implemented, you can delay the launch of this upgrade |
---|
| 92 | script until you really need Group Print Quotas. |
---|
| 93 | In other terms, running this script is not mandatory |
---|
| 94 | for PyKota to continue to work correctly, at least |
---|
| 95 | until Group Print Quotas will be fully implemented. |
---|
| 96 | |
---|