1

Today I wanted to make more free room on my C:/ driver and I saw Postgresql has like 8GB so I wanted to move it to another part of my hdd so I just copy and pasted it, but i had to first quit everything that had SQL or postgres in task bar to be able to move it, but things stopped working so i decided to uninstall postgresql.

Now I want to install it back, but everytime I try to I get this error: An error occured executing the Microsoft VC++ runtime installer when I run 8.3 and 8.4 version and when I try 9.x version of postgresql I get this error: Unable to write inside TEMP environment variable path. heres pic: http://oi40.tinypic.com/rb06eh.jpg

Can you please help me what to do ? i have been trying to fix this problem for like 2 hours, but nothing works.

Chris Travers
  • 25,424
  • 6
  • 65
  • 182
petr pol
  • 11
  • 2
  • If 8gb is 'too big' then I suggest you get a bigger HDD. You can get a terabyte for under $100 quite easily these days. You cannot just move a windows application's files around and expect it to keep working. – Marc B Feb 27 '12 at 14:43
  • i have 600GB HDD, but yea...that was stupid thing to do – petr pol Feb 27 '12 at 15:06
  • http://stackoverflow.com/q/28471348/330315 –  Jun 26 '16 at 08:16
  • You may want to try the solution to [this question](https://stackoverflow.com/questions/4288303/cant-install-postgresql-an-error-occurred-executing-the-microsoft-vc-runtime) to solve the VC++ runtime installer issue: https://stackoverflow.com/questions/4288303/cant-install-postgresql-an-error-occurred-executing-the-microsoft-vc-runtime. I used the command they suggest in Run.exe and it worked on Windows 10, (sorry, I come from the future;) – epicTreeStick Jan 24 '19 at 08:15

1 Answers1

0

The simple solution is copy your data directory to a backup location with postgreSQL stopped, then uninstall PostgreSQL and reinstall it. This gives the installer a chance to fix a bunch of things.

Note that if you want to move data somewhere else you can always create tablespaces on your other drive and move your tables there. That's better than copying the whole installation.

Chris Travers
  • 25,424
  • 6
  • 65
  • 182