LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-03-2013, 06:26 AM   #1
veeruk101
Member
 
Registered: Mar 2005
Distribution: Ubuntu 12.04 LTS
Posts: 249

Rep: Reputation: 16
How to mount SSHFS on startup when key-based authentication isn't possible?


I have 2 drives in a NAS I'd like to mount through SSHFS, but because of some limitations of the NAS it's not possible to use key-based authentication, so I must use a password. Because of this, am I correct to think that using fstab is not a possibility?

What would be the correct way to mount these drives? I can't do it in my bash profile files, because it needs to be available earlier than that in system startup, because the backup application that I use, called CrashPlan, starts backing up as the root user when the system boots up (through I believe an init script), so it expects the backup locations to be accessible then.
 
Old 05-03-2013, 07:14 AM   #2
lleb
Senior Member
 
Registered: Dec 2005
Location: Florida
Distribution: CentOS/Fedora
Posts: 2,630

Rep: Reputation: 495Reputation: 495Reputation: 495Reputation: 495Reputation: 495
what is the file format of the NAS? is it possible to mount it as a CIFS or NFS share? as for sshfs you are correct without ssh keys you are not going to be able to mount until the system is up and running. it could be done via a bash script using expect to hold your p/w, but that would defeat the sshfs security as you would then be transmitting the p/w in plain text.
 
Old 05-03-2013, 07:19 AM   #3
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 9,435

Rep: Reputation: 2769Reputation: 2769Reputation: 2769Reputation: 2769Reputation: 2769Reputation: 2769Reputation: 2769Reputation: 2769Reputation: 2769Reputation: 2769Reputation: 2769
so you will probably need to write another init script to do the job (and execute it before CrashPlan)
 
Old 05-04-2013, 05:23 AM   #4
veeruk101
Member
 
Registered: Mar 2005
Distribution: Ubuntu 12.04 LTS
Posts: 249

Original Poster
Rep: Reputation: 16
I ran "sudo find /etc | grep crashplan" and got the following output:

Code:
/etc/init.d[/crashplan
/etc/sysctl.d/60-crashplan.conf
/etc/rc2.d/S99crashplan
Is it okay for me to put the mount commands in /etc/rc.local if I want them to run before the rc*.d/ scripts, or should I do it differently?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] SSH2 RSA key based authentication acunacha Linux - Server 4 11-08-2012 09:32 AM
SSH Key based authentication failure kdheepan Linux - Newbie 2 06-08-2011 07:55 AM
problem with ssh key-based authentication kaplan71 Linux - Security 5 12-09-2009 10:34 AM
Key based authentication only for root for SSH the_gripmaster Linux - Security 4 04-18-2009 05:43 PM
problem doing sshfs mount with public key authentication Sambatyon Linux - Networking 1 06-15-2008 07:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 10:31 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration