Skip to main content

All Questions

Tagged with
46 votes
7 answers
138k views

How to automatically run commands on SSH login?

Whenever I login to my Linux server I'd like to have several commands run automatically (set some variables, change location, etc.) This needs to be done on user login, not on system start. How can ...
Alasdair's user avatar
  • 867
36 votes
6 answers
80k views

To use ssh-id-copy do you need both id_rsa.pub and id_rsa?

I am trying to setup a second access ssh key for a friend. He sent me his id_rsa.pub. ssh-copy-id -i id_rsa.pub [email protected] /usr/local/bin/ssh-copy-id: ERROR: failed to open ID file './...
user avatar
33 votes
5 answers
140k views

Where to find SSH Login log files on centos

I have shared a .pem file with few a developers and now something went wrong on the server. I would like to track logins in a log so that I can see who (IP) made changes and when (if even possible) ...
ULLAS K's user avatar
  • 433
31 votes
3 answers
32k views

sshfs is failing with "remote host has disconnected"

I'm running sshfs with the following: sshfs [email protected]:/var/www/myapp /home/basicuser/code -o sftp_server="/usr/bin/sudo /usr/libexec/openssh/sftp-server" I have also created RSA keys ...
Don Rhummy's user avatar
15 votes
2 answers
92k views

How can I set an environment variable permanently in CentOS?

I used a following commmand in SSH terminal on my server: export LD_LIBRARY_PATH=/lib:/usr/lib:/usr/local/lib and it works fine: my program finds all libraries at this point (if I launch it from my ...
user3545570's user avatar
13 votes
1 answer
43k views

SSH: "no such identity"

I'm having a very peculiar problem getting SSH to work on my Linux box. I have a passwordless git user identified by an OpenSSH key. If I attempt to ssh into it from either the same or a different ...
Kris Craig's user avatar
6 votes
2 answers
8k views

Delete duplicate files with rsync

Here is the thing , I have a folder on my server with 50 GB size and its' containing over 60000 file. I used rsync to transfer it to a mirror server and almost half of file has been transferred.Now i ...
codedme's user avatar
  • 173
6 votes
1 answer
5k views

How to setup password-less ssh between two vagrant machines?

I have set up a enviroment of two machines in vagrant where I used the following CentOS image: http://developer.nrel.gov/downloads/vagrant-boxes/CentOS-6.4-x86_64-v20130427.box Lets call the two ...
Leonard Saers's user avatar
3 votes
2 answers
8k views

Fast way to check disk usage in linux?

I want to find out the disk usage of /home however it's too slow, I get timeout sometimes (SSH) because it has lots of files. I am using du -sh /home and I was wondering if there's a faster way?
IMB's user avatar
  • 5,533
3 votes
2 answers
131 views

Add ssh key file for linux server - Key generated, then what?

I want to build a CentOS7 server by myself. Now I already followed the steps mentioned in this link: https://www.digitalocean.com/community/tutorials/initial-server-setup-with-centos-7, which ...
Charles Zha's user avatar
3 votes
1 answer
246 views

What's the CentOS equivalent of ssh-keygen -E?

The ssh client is asking me if the fingerprint of a new server is okay. This fingerprint is sha256. The ssh server can tell me its fingerprint with ssh-keygen -l -f /etc/ssh/ssh_host_ecdsa_key ...
spraff's user avatar
  • 2,228
2 votes
2 answers
768 views

Split large files into files with .001 .002 (and so on) extension in CentOS via Terminal

How to split large files into parts with .001 .002 (and so on) extension in CentOS via SSH Terminal (using Putty)? For example, if I have a large file - LargeFile.iso, then how can I be able to split ...
Phoenix's user avatar
  • 143
2 votes
2 answers
382 views

ArchLinux Virtual Machine can only be logged in through SSH after logging in through virt-manager

I installed two ArchLinux virtual machines on my CentOS server with virt-manager on KVM. The ip addresses are 192.168.1.138 and 192.168.1.183. After installation, I installed OpenSSH and copied the ...
Hans Xeng's user avatar
2 votes
1 answer
2k views

Centos Sftp Ssh - How always create files with rwx-rwx-r-x and always owned by a certain group

I have a user myuser, which is only allowed to connect to ssh via sftp. I'd like this user to always create files with rwx-rwx-r-x and always owned by the group apache. I've tried to accomplish the ...
Jojo Coana's user avatar
2 votes
2 answers
2k views

SSH Using Wrong ID

I am trying to establish password-less ssh to myself on a CentOS6 system. I go through the following steps: ssh-keygen -t dsa -P '' -f ~/.ssh/id_dsa cat ~/.ssh/id_dsa.pub >> ~/.ssh/...
JHowIX's user avatar
  • 125

15 30 50 per page
1
2 3 4 5
8