Skip to main content
9 events
when toggle format what by license comment
S Mar 19, 2017 at 14:49 history suggested Hassan Baig CC BY-SA 3.0
Just ensuring no one mixes up the `ln` command (like I did). Would be great for future readers as a complete reference as well! Feel free to fix this in case I've made a mistake.
Mar 19, 2017 at 13:01 vote accept Hassan Baig
Mar 19, 2017 at 13:00 review Suggested edits
S Mar 19, 2017 at 14:49
Mar 19, 2017 at 10:40 comment added user1822 If the temp dir is not used, I think it should be safe without shutting down.
Mar 19, 2017 at 10:30 comment added Hassan Baig How critical is shutting down postgresql for this? My $PGDATA/base/pgsql_tmp location has always been empty - it's only after running some special big analytical queries that temporary files were created.
Mar 19, 2017 at 10:15 comment added user1822 Yes, the symlink looks correct. Note that it would be safer to shut down Postgres before doing that. And the linked server is about permission problems - of course you need to make sure that the Linux user postgres is allowed to write into the temp directory.
Mar 19, 2017 at 10:10 comment added Hassan Baig Secondly, could there be any reliability issues with this kind of arrangement? For instance, the OP here tried a symlink, but ran into issues (as per their comment): stackoverflow.com/a/18819514/4936905
Mar 19, 2017 at 9:52 comment added Hassan Baig Ye I'm cognizant of the location of temporary pg files. So to confirm, you mean I symlink via ln -s $PGDATA/base/pgsql_tmp /mnt/pgsql_tmp, and then as per how soft links work, the OS will simply access the data in the file named by the data in the symlink (i.e. save and manipulate pg temp files at /mnt/pgsql_tmp). Correct?
Mar 19, 2017 at 8:57 history answered user1822 CC BY-SA 3.0