[LIVE] sftp'ing - how to write (overwrite) files?

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
KidKiwi Offline
Posting Freak
Posts: 833
Joined: May 2007
Reputation: 0
Post: #1
Using filezilla to sftp into the live distro, I can't seem to be able to write a file to it (or overwrite existing files). This is probably a permission issue, but I don't know how to overcome this. What am I missing? Thx muchly.

ZOTAC IONITX-D-E Intel Atom N330 Dual Core 1.6 GHz NVIDIA ION with LIVE on SSD
find quote
m3g4tr0n Offline
Senior Member
Posts: 141
Joined: Jan 2010
Reputation: 0
Post: #2
are you using the root account?
find quote
KidKiwi Offline
Posting Freak
Posts: 833
Joined: May 2007
Reputation: 0
Post: #3
m3g4tr0n Wrote:are you using the root account?

I'm not sure what you mean by this??

I fire up filezilla using the correct ip, username and passwd and all the files appear as it should. But i can't change anything.

Should I be doing something else?

ZOTAC IONITX-D-E Intel Atom N330 Dual Core 1.6 GHz NVIDIA ION with LIVE on SSD
find quote
prae5 Offline
Team-XBMC Forum Moderator
Posts: 2,064
Joined: Jan 2009
Reputation: 34
Location: Cambridge, UK
Post: #4
What files are you trying to change and what user account are you connecting with?
find quote
X3lectric Offline
Closed Account
Posts: 1,756
Joined: Feb 2006
Location: in a Dropbox
Post: #5
KidKiwi Wrote:I'm not sure what you mean by this??

I fire up filezilla using the correct ip, username and passwd and all the files appear as it should. But i can't change anything.

Should I be doing something else?

username should be root
password whatever password set for root

to set a root password.
passwd root (then enter same password twice)

Linux by default doesn't enable root login to enable root login type on terminal xbmc by default cant overwrite all files either only within .xbmc

The chown command can also be used say sudo chown username -R / that allows whatever username you using to have write access to everything. But only after running either of these on terminal (may take a while for chown) will your sftp connection have permission to do whatever.

Mind this is not for noobs, editing some unix files in windows will bork the files, e.g. edit fstab will bork fstab that in turn will cause system to become unbootable (it can be fixed but not so easy for noobs)
(This post was last modified: 2010-09-13 12:55 by X3lectric.)
find quote
KidKiwi Offline
Posting Freak
Posts: 833
Joined: May 2007
Reputation: 0
Post: #6
prae5 Wrote:What files are you trying to change and what user account are you connecting with?

I'm trying to sort things on a new system setup (Ion-based running Dharma Live). I have be doing a lot of ssh'ing, but there are things I don't know how to do that way - so I try via sftp'ing (without any luck). Ultimately, I'll need to tweak keymaps, skins etc.

To login via sftp-ing (filezilla) I use the login and password I created at setup - in this case xbmc (x2) - but it won't let me change anything. It would seem I have to login as root and setup up a new root passwd. I'll give this a go. ( I assume I have to set the new root passwd via ssh (putty)? Thx

ZOTAC IONITX-D-E Intel Atom N330 Dual Core 1.6 GHz NVIDIA ION with LIVE on SSD
find quote
Fonzie83 Offline
Junior Member
Posts: 14
Joined: Aug 2010
Reputation: 0
Post: #7
I have the same problem. Can access all files through Filezilla but can't write files. Was planning on transferring a few video files to my hard drive in my Revo this way for ease.

Will the root account solve this?
find quote
gsgleason Offline
Donor
Posts: 172
Joined: Oct 2009
Reputation: 5
Post: #8
KidKiwi Wrote:I'm trying to sort things on a new system setup (Ion-based running Dharma Live). I have be doing a lot of ssh'ing, but there are things I don't know how to do that way - so I try via sftp'ing (without any luck). Ultimately, I'll need to tweak keymaps, skins etc.

To login via sftp-ing (filezilla) I use the login and password I created at setup - in this case xbmc (x2) - but it won't let me change anything. It would seem I have to login as root and setup up a new root passwd. I'll give this a go. ( I assume I have to set the new root passwd via ssh (putty)? Thx

You need to learn about linux file permissions and ownership. What is the full path to the file you're trying to overwrite? Look at the ownership and permissions with 'ls -l /path/to/file' and paste here, as well as output from command 'groups'
find quote
josei98 Offline
Junior Member
Posts: 8
Joined: Nov 2010
Reputation: 0
Location: Mexicali, Mexico
Post: #9
I just made a stupid thing. I use "sudo chown username -R /" to edit a file. I did but now I'm not able to load xbmc. Its asking me for the username and password (both are xbmc of course) Once a type both, nothing happens. Help!!
sincerally... a stupid noob
find quote
Mindzai Offline
Fan
Posts: 333
Joined: Aug 2010
Reputation: 0
Post: #10
Unfortunately you have set the owner of every file in your system to username. You should be really careful about copying commands directly without understanding them for this reason, because the people posting them don't always know what they're talking about.

I don't really know what you can do to fix this. You could try assuming that the owner of all files outside of home directories was root and set them all back, then set your home directory back to the correct user. Otherwise you could back up your home directory and reinstall.
(This post was last modified: 2011-05-18 13:38 by Mindzai.)
find quote
prae5 Offline
Team-XBMC Forum Moderator
Posts: 2,064
Joined: Jan 2009
Reputation: 34
Location: Cambridge, UK
Post: #11
josei98 Wrote:I just made a stupid thing. I use "sudo chown username -R /" to edit a file. I did but now I'm not able to load xbmc. Its asking me for the username and password (both are xbmc of course) Once a type both, nothing happens. Help!!
sincerally... a stupid noob

You have changed the ownership of every file on your system - this will potentially make all sorts of weird and not so wonderful things happen.

You may be able to fix this, but honestly your quickest way forward will more than likely be to reinstall things, especially if you aren't very experienced.
find quote
josei98 Offline
Junior Member
Posts: 8
Joined: Nov 2010
Reputation: 0
Location: Mexicali, Mexico
Post: #12
Mindzai and Prae5, thank you, I will re install and I'll be more careful next time. best regards from Mexico
find quote
X3lectric Offline
Closed Account
Posts: 1,756
Joined: Feb 2006
Location: in a Dropbox
Post: #13
and enable root login and setup a root password on install to prevent this from happening.
find quote