Tag Info

Hot answers tagged

8

Just restarting postgres is not a long term solution, you will hit the limit again, unless you have physical resource constraints on the server such as memory. During the issue the number of processes opened(nproc) by postgres user was 503 and the estimated number of open files(nofile) was 35225 and yet your postgres_limits.conf shows that you have set nproc ...


5

You are dealing with AFS, which is a networked file system. I suspect that you are probably bumping into a quota limit. You will need to work with the administrator of that service.


3

What you're likely looking for is called a Distributed File System. These require special handling and are not part of normal distro installations. There is a Wikipedia article containing a non-exhaustive list of distributed file system platforms. The main selling point of distributed file systems is redundancy, scalability, and access transparency. Like ...


2

Escaping special char / is an option. You can also change the default sed separator (which is /) by using ? for example : another_unix_path="/another/unix/path" echo /some/path/file.txt | sed -e 's?/some/path/file.txt?'$another_unix_path'?g' The char used just after the s flag defines which separator will be used : s? Edit : #!/bin/sh ...


2

Actually it's better to use /etc/profile.d for this option. And source script there. It would display output on every login. About the second problem and breakinf sftp. I did a little bit googling. You can use: Subsystem sftp /usr/lib/openssh/sftp-server in your /etc/ssh/sshd_config. Or add if [ "$SSH_TTY" ] then source .bashc_real fi to your ...


1

In Ubuntu/Debian, PAM module pam_motd supports that dynamic motd functionality, and supposedly it doesn't interfere with sftp. Unfortunately it's not well documented. You can instead consult update-motd manpage in Ubuntu. On the Ubuntu systems you already have several scripts in /etc/update-motd.d/. They are live examples suitable for your own to start ...


1

You should add -pubin for public key inputs. openssl rsa -pubin -in user_id_rsa.pub -inform DER -outform PEM -out pubkey.pem EDIT: To handle PEM RSA PUBLIC KEY format, specify -RSAPublicKey_in -RSAPublicKey_out instead. openssl rsa -RSAPublicKey_in -in user_id_rsa.pub -inform DER -outform PEM -out pubkey.pem -RSAPublicKey_out If you want to convert ...


1

Simply using grep: grep . file Or try ex-way: ex -s +'v/\S/d' -cwq test.txt For multiple files (edit in-place): ex -s +'bufdo!v/\S/d' -cxa *.txt Without modifying the file (just print on the standard output): cat test.txt | ex -s +'v/\S/d' +%p +q! /dev/stdin


1

If you use / for separators, then you'll have to escape every / in your path, ex sed 's/\/some\/path/'$replacement'/g' Fortunately sed - like Perl - allows many characters to be used as separators, so you can also write sed 's#/some/path#'$replacement'#g' (the g flag is used to allow replacing multiple occurrences per line). Also sed will not allow ...


1

try nohup bash -c "./myscript.sh 11111" > nohup.out


1

Looks like a job for NFS. You can make server01 an NFS server that exports the /total_app directory. Then you can allow all servers to mount it. You must only be sure that server01 is always up, running, and accessible. Also be careful that the servers are not 'destroying' each other configurations for the applications in the directory.


1

If you take a look to sftp manual (sftp(1)) you can see there is a way to perform a ls sorting by mtime (ls -t). So you can run sftp twice: First time you perform a ls -lt (or ls -lrt to reverse order) redirect the output to a file and just read the last line of listing, so you have the filename, and on the second round you can specify the file to download. ...


1

Check your inode usage via df -i - on a standard partition, you could have exhausted your inode limits on the filesystem. This most often happens when you're storing lots of small files (for example, cache). Your df -h output suggests that you have zero bytes in use on that partition, so this could also be access or mount permissions on the underlying AFS ...



Only top voted, non community-wiki answers of a minimum length are eligible