NuxNik
Posts: 3
Joined: Sun Jun 30, 2013 5:30 pm

ssh - connection refused - moving /var to own HD partition

Tue Oct 28, 2014 9:08 pm

Hello
New to Arch Linux
1+ year experience with Lubuntu (PC & laptop) & Raspian (Raspberry Pi).
40+ years as computer geek.
Have been running Raspian on my Raspberry Pi.
Under Raspian, I was able to move "/" to a USB Hard Drive. and set up separate /Var and swap partitions on the same HD. Ssh into the RasPi - no problems.
Decided to try installing Arch Linux on the RasPi. And basically do the same setup
1) Just installed Arch on SD and ran it. Ssh works fine out of the box. Same for wired lan connection. On reboot ssh worked fine..
2) Then created the swap partition, modified fstab, activated it, On reboot, ssh was fine.
3) Created new HD partition for "/", used dd to copy it from mmcblk0p2. Changed the pointers in cmdline.txt. Modified Fstab, Rebooted. All OK - ssh works
4 Created a partition for /var. Used dd to copy /var from the HD /var to new partition on the HD, updated fstab to point to the new partition.
4) On reboot, could not use ssh. "connection refused".
4) Able log on to Pi. Access /var files no problem. Also able to ping on both server (Raspi) and client (Lubuntu desktop) from the other. But no ssh.
5) Commented out the fstab entry so /var was on same partition as /. Ssh works.
6) Changed fstab to point to new partition = ssh connection refused.
7) Nothing in Dmessg to show any other problems..
I am stumped.
What am I missing ?

By the way, I was just copying what I already have operational in Raspian

Got nowhere on the Arch-Arm forum. Was sent away from the ArchLinux forum to the Arch-Arm forum.

Any ideas ?

sdjf
Posts: 1395
Joined: Fri Mar 16, 2012 5:20 am
Location: California
Contact: Website

Re: ssh - connection refused - moving /var to own HD partiti

Wed Oct 29, 2014 5:54 pm

You might need to restart the ssh daemon. Is it running when the connection is refused?
FORUM TIP: To view someone's posting history, sign in, click on their user name, then on "Search User's Posts." || Running ArchLinuxArm on Model 2B and 512MB Model B

pepedog
Posts: 1043
Joined: Fri Oct 07, 2011 9:55 am

Re: ssh - connection refused - moving /var to own HD partiti

Wed Oct 29, 2014 8:48 pm

The only time I got ssh refused is when rootfs got mounted as read only
Maybe swinging var away makes logs that were already created disappear? See if sshd.service can be restarted like advised

sdjf
Posts: 1395
Joined: Fri Mar 16, 2012 5:20 am
Location: California
Contact: Website

Re: ssh - connection refused - moving /var to own HD partiti

Sat Nov 01, 2014 12:23 am

If restarting the ssh daemon does not work, run route and ifconfig commands to see what is going on. Possibly the Pi changed IP addresses on you when you moved the root partition? Just a wild guess, but something else to look at. Also, the pi might be running ethernet on eth1 instead of eth0, for example.
FORUM TIP: To view someone's posting history, sign in, click on their user name, then on "Search User's Posts." || Running ArchLinuxArm on Model 2B and 512MB Model B

FM81
Posts: 518
Joined: Wed Apr 17, 2013 4:33 pm

Re: ssh - connection refused - moving /var to own HD partiti

Sat Nov 01, 2014 11:20 am

First idea for debugging: Have you tested SSH-connections in verbose-mode?

Code: Select all

ssh -vvv <all_the_rest>
May be you can see something useful ...

Second idea: permissions of the top of the VAR-partition are set correctly? May be, something wants to write and cannot ...

MfG, FM_81
A: What does the command 'cat /dev/urandom', can you tell me please?
B: Yeah, that's very simple: It feeds your cat with radioactive material!

Return to “Arch”