我一直试图在这台机器上安装postgres 10.5,尽管我设置了安装路径,但它总是每次都选择那个特定的目录..专家请帮助我。
[root@DBSRV01 postgres10upd]# ./postgresql-10.4-1-linux-x64.run --datadir /opt/postgres/10.5/data --prefix /opt/postgres/10.5/ --debuglevel 4 --serverport 5433 --superpassword postgrespwd --servicename postgres-10
----------------------------------------------------------------------------
Welcome to the PostgreSQL Setup Wizard.
----------------------------------------------------------------------------
Select the components you want to install; clear the components you do not want to install. Click Next when you are ready to continue.
PostgreSQL Server [Y/n] :y
pgAdmin 4 [Y/n] :n
Stack Builder [Y/n] :n
Command Line Tools [Y/n] :y
Is the selection above correct? [Y/n]: y
----------------------------------------------------------------------------
Please select a directory under which to store your data.
Data Directory [/opt/postgres/10.5/data]:
----------------------------------------------------------------------------
Please provide a password for the database superuser (postgres). A locked Unix user account (postgres) will be created if not present.
Password [********] :
Retype password [********] :
----------------------------------------------------------------------------
Please select the port number the server should listen on.
Port [5433]:
.
.
[222] en_US
.
.
[716] zu_ZA
[717] zu_ZA.iso88591
[718] zu_ZA.utf8
Please choose an option [1] : 222
----------------------------------------------------------------------------
Pre Installation Summary
The following settings will be used for the installation::
Installation Directory: /root/postgres10upd/y
Server Installation Directory: /root/postgres10upd/y
Data Directory: /opt/postgres/10.5/data
Database Port: 5433
Database Superuser: postgres
Operating System Account: postgres
Database Service: postgresql-10
Command Line Tools Installation Directory: /root/postgres10upd/y
Press [Enter] to continue:^Z
[3]+ Stopped ./postgresql-10.4-1-linux-x64.run --datadir /opt/postgres/10.5/data --prefix /opt/postgres/10.5/ --debuglevel 4 --serverport 5433 --superpassword Mam5pg@1 --servicename postgres-10
[root@DBSRV01 postgres10upd]#
我哪里做错了?为什么一次又一次地选择该目录?是存储在某处并从那里读取,这就是为什么总是选择相同的目录?
PS:使用LVM将SAN安装到opt目录。我已经在其他2台具有相同h / w和s / w配置的机器上成功安装,除了没有安装SAN。
刚刚安装在具有相同配置+ SAN的另一台计算机上..工作得很好[root @ DBSRV02 postgres] #service postgresql-10 status pg_ctl:服务器正在运行(PID:53224)/opt/postgres/10.5/bin/postgres“ -D“”/ opt / postgres10.5 / data“。
是因为安装一旦失败,从那时起该位置就已修复。有人请告诉我如何删除第一次失败安装的残留物。
好的伙计们,谢谢大家的帮助!我通过使用命令搜索目录找到了罪魁祸首
grep -rlw“postgres10upd”
然后我意识到有这个文件
/etc/post GRE是-reg.INI
有一个条目
InstallationDirectory = /根/ postgres10upd / Y
我把它编辑成“/opt/postgres/10.5”
然后在安装时没有问题,并安装到我想要的确切位置。