Hi here!"sudo -u postgres psql mybbdd" works propery on Centos 5.x but we have problems with the same installation prototype on Centos 6.3Postgres 9.1 commands are... [by Daniel2d2art]
on 10/31/2012 – Made popular on 10/31/2012
TO make a database backup in postgreslq server you use pg_dump and psql commands.
First, locate the database:
# psql -l --username postgres --password
# pg_dump --username postgres name_db --file /dir/dir/backup.sql
To restore the database:
First create database with its respective name and roles:
# psql postgres
# postgres=# CREATE DATABASE name_db ENCODING 'UTF-8';
# postgres=# CREATE ROLE
Whilst attempting to install some tricky software (for astronomical data reduction) I hit software installation problems running as sudo. I therefore tried the same thing running as my normal user, after modifying the permissions of /usr:
chmod -R 777 /usr
This was intended to be a temporary mod and seems to have been a bad idea.
Hey guys. Recently, (possibly as of zsh 4.3.15), whenever I'm in ~, zsh has been prompting me to autocorrect sudo vim $filename to sudo .vim $filenameWithout "sudo", zsh makes no attempt to uncorrect "vim", which vaguely reminds me of having a sudo="sudo " alias in bash to get autocompletion working for sudo commands.
I am using:
putty.exe -ssh -2 -l myusername -pw mypasswd C:\myCmd.txt 192.168.1.12
on a window cmd line, so I can send a list of commands from the file "C:\myCmd.txt " to the remote device.
Does anyone knows which commands can be sent and which one not? Before I start to pull my hair out.
I would really appreciate if you have some example that works and some that doesn't.