problem/bug in drop tablespace?
От | Michael Nolan |
---|---|
Тема | problem/bug in drop tablespace? |
Дата | |
Msg-id | CAOzAquJzjmxYXxkmV9ee2JGz0vG1qubRu6DZG+6uU5Tr6odpOQ@mail.gmail.com обсуждение исходный текст |
Ответы |
Re: problem/bug in drop tablespace?
Re: problem/bug in drop tablespace? |
Список | pgsql-hackers |
While researching a problem reported on the -general list by a user who lost a disk containing his index tablespace, I raninto something, but I'm not sure is a serious bug or just an inconsistency in how \d shows tables. <br /><br />Hereare the steps I took.<br /><br />1. Create a new database 'MYDB' and connect to it.<br />2. Create a new tablespace'MYTBLSP'<br />3. Create a table 'MYTABLE' and populate it.<br />4. Create an index 'MYIND' on that table, withthe index in the new tablespace, MYTBLSP.<br /><br />Now, exit psql and delete the files in the tablespace directorycreated in step 2, simulating the problem the user had.<br /><br />Trying to execute an SQL command on the tableMYTABLE will, as expected, generate an error.<br /><br />Now, drop tablespace MYTBLSP. This will produce an error,but it will delete the tablespace according to \db.<br /><br />Recreate tablespace MYTBLSP.<br /><br />Regenerate theindex on MYTABLE. Queries will work on this table again, as expected.<br /><br />Now, here's the problem I ran into:<br/><br />The index will be rebuilt in tablespace MYTBLSP, but \d on table MYTABLE will not show the index as beingin that tablespace.<br />--<br />Mike Nolan<br /><br /><br /><br />
В списке pgsql-hackers по дате отправления: