ProFTPd read-only

How do I setup root access or create any other users with write capability?

Thanks.

I’m not sure I understand your question …

Dietpi should give you read-write access, but out of the box it will jail you in the root directory if that is what you have log on as.

To see the full file system you need to edit:

/etc/proftpd/proftpd.conf

And comment out:

#This will jail users in one directory -gw change
#DefaultRoot /root

Gordon Williams

Jailing is not the thing I’m talking about. I can’t write anything to FTP with the root user or with another non-root user I’ve created for netatalk.

Sorry, no idea what netatalk is. I presume that you have already check permissions on the directory and that you can log onto the device (rpi??) or ssh into it and read-write normally.

Gordon Williams

Yup, permissions are okay, ssh working well. Netatalk is an Apple File Protocol, mainly used to backup mac’s via their Time Machine software.

I’m having a similar issue. I run dietpi on a raspberry pi 2 B+, and just upgraded from 1.2x to 1.47. After the upgrade I cannot add or delete files on my attached usb hard drive using FTP or using Samba. Previously both methods were able to read, write and delete files. I also removed Samba and began to use NFS for LAN access, but access is still read only, despite configuring readwrite access.

Here is the relevant line in /etc/exports on the dietpi:
/mnt/usb_1 192.168.0.235(rw,sync)

Here is the relevant line in /etc/fstab on my desktop pc running debian:
192.168.0.100:/mnt/usb_1 /home/a***/dietpi_NAS nfs rsize=8192,wsize=8192,timeo=14,intr

Transmission bittorrent can still add and delete files. It seems to be some kind of security problem, but I’m not savvy enough to know where to look.

edit: looked a bit further and found that ProFTPd could in fact perform operations on some directories and not others. The ones it could work on were in the group ‘root’, and the ones it could not were in the group ‘nogroup’ (which did not exist). I used chown to let root be the owner for all directories and files on the hard drive. This solved the FTP access problems, and transmission still works ok, but NFS still did not work as I don’t log in as root to my desktop. To solve that I changed permissions to 0777, not ideal, but it worked. Ideally I should go back to Samba and mount the drive with a login name and password to gain root access from my desktop pc, which I’ll get round to sometime.

I think in the past when I have been using Samba to access and transfer files in, they came in owned by ‘nobody’ and in ‘nogroup’, possibly when using Grsync with incorrect switches. I’m still not sure why it worked okay before and then became a problem after the upgrade, but at least I have a solution.

hi,

Could be a permissions issue, try reapplying required permissions to userdata folder:

/DietPi/dietpi/dietpi-software setpermissions

Restart services

dietpi-services restart