|
|||||||
|
just one morea quick question from you archlinux geniuses here. Say i've shared a full usb drive (/mnt/Disk1). I've set myself as the only one with write permission. I have another read only account. Now say I have a folder in Disk 1 (/Disk1/Backup) that i only want to be able to access/view with my login, and the other samba user i have (pcguest) should not be able to view the contents of the folder. If the folder is hidden, great, but its not necessary. I just don't want others to be able to view the contents of that folder.
How do i work that? |
| 01-28-2013, 08:02 AM | |
|
|
|
The only tricky thing about sabnzbd installation is the permissions. Make sure you have sabnzbd installed: # pacman -Qs sabnzbd if the info shows up as result then you already have sabnzbd installed. If not, you have to get it from AUR (Arch User Repository). In this case installing a AUR package manager/broker will save some time (for now and in the long run) and I like yaourt. It's like other package managers such as yum, apt, emerge which can automatically search and install the required dependencies for the package you want to install. Here is how to install yaourt: Be sure that your system time is sync'ed with the time server pool otherwise the certificate may not be working when yaourt tries to use wget to get the stuff from https hosts. (I simply create a systemd script `ntpd -gq` so the system's time is always adjusted when it boots up - too lazy to use ntp client as a service or use cron). yaourt install: 1. # pacman -Sy wget base-devel yajl ed 2. # wget https://aur.archlinux.org/package...ery.tar.gz 3. # tar zxvf package-query.tar.gz 4. # cd package-query 5. edit PKGBUILD and change arch type to "any" 6. # makepkg --asroot PKGBUILD 7. # pacman -U <package.xz> 7. # wget https://aur.archlinux.org/package...urt.tar.gz 8. # tar zxvf yaourt.tar.gz 9. # cd yaourt 10.# makepkg --asroot PKGBUILD 11.# pacman -U <package.xz> Feel free to delete everything that was downloaded or created during the above steps after the software is up and running. the steps also show how to install packages from the source by using PKGBUILD file. It's easier than compiling from the source (./configure; make; make install) and you have a package at the end so it makes removing the package cleaner and easier if you don't want it. To install sabnzbd simply do # yaourt -Sy sabnzbd and follow the script's instruction to get it done. The default sabnzbd base path is /opt/sabnzbd if you get it from AUR. Make sure /opt/sabnzbd and all the subdirectories is owned by the user you use to run sabnzbd. You can find that info in /usr/lib/systemd/system/sabnzbd.service, the location is where all the start/stop scripts used by systemd to control the software. Use the following command to change the ownership of an entire folder and everything in it: # chown -R nobody.nobody /opt/sabnzbd //change the ownership to nobody user and nobody group there may be other locations for sabnzbd files such as /etc/conf.d/ but in this case only /opt/sabnzbd needs attention (if I remember correctly). Sickberad is a whole different deal because it doesn't have a base directory so the files are all over the place. To check all the files installed from a package: # pacman (or yaourt) -Ql <package name> | less After that you are all set, just start the service (# systemctl start sabnbzd) and go to the webpage (http://<IP>:8080/sabnzbd (the port number is listed in /opt/sabnzbd/sabnzbd.ini) and set all the configuration options before you start to have fun with it. Performance note: pogo's 256MB ram obviously is not enough for lots of things, one of them is too many job queue in sabnzbd. They could be from sickbeard or other sources. We don't want to use too much drive space for cache either because of the flash drive short life cycle. You just have to test out the best settings for your own system. |
|
|
|
|
|
I'm thinking "veto files" is the option you're looking for. add the line in smb.conf under the particular share to exclude sub-directories explicitly [myshare] path = /var/test veto files = /var/test/private more syntax examples here: http://www.samba.org/samba/docs/m...#VETOFILES |
|
|
|
|
|
thanks...giving this a shot now.
I did see the statistics tools you listed (iostat was one of them i think) and all say command not found. so i will install those. a few questions on the san setup: Pacman vs yaourt. i thought pacman was infact a package manager...isnt that what we were doing with all those packman -Sy package name commands? Or are they different "repositories" of packages? anyway ofcourse I'm going to follow your instructions down to a dot but just asking out of curioisty. " Use the following command to change the ownership of an entire folder and everything in it: # chown -R nobody.nobody /opt/sabnzbd //change the ownership to nobody user and nobody group " i know one of the previous configs (samba or hfs) you had also mentioned nobody user and nobody group. I am not clear what that means. do you mean i should replace nobody.nobody with my own username and groupname? Or is that a generic linux term to make sure everything is controlled only by admin? anywhere i see nobody nobody mentioned (and ive seen it in a few guides) should i just leave it at as mentioned?
|
|
|
nobody is a non-privileged system user (also has its own group: nobody). Several services use it (by default) to run the service programs (instead of using root account) such as samba, nfs, and sabnzbd (you can always change them to whatever account you like in the configuration files or systemd scripts). Take a look at /etc/passwd and /etc/group, get familiar with the format by comparing other users and you will know it's just a normal user account and no different then others (except the default shell for nobody is disabled so you can't log into the system with "nobody" account). You have been doing a lot of linux stuff in the past couple of weeks and it's easy to get overwhelmed. Just step back and relax a little and give it some time to digest. |
|
|
i have a question though. my shares are unmounting themselves after a few hours of inactivity (from my ubuntu desktop, not the pogoplug). i have hdparm -S 120 /dev/sdb set in my /etc/rc.local file to automatically spin the drives down after 10 minutes. is that what's causing it? so, basically, i have the drives attached to the pogoplug, and then share them via nfs to an ubuntu server that i have plex media server installed on, so that i can use plex. the solution works fine, but the problem im having is that the shares are unmounting from the ubuntu server after a while. does anyone have plex media server on the pogoplug? i thought about it, but i dont think it's powerful enough to transcode mkv files to my ps3, that's why i have it set up like this. you might wonder why i dont just have the drives running from the ubuntu server, and that's because i only turn on the server when i want to watch something with my ps3. if i want to watch on my computer or something else, then watching straight from the pogoplug works fine. |
|
|
thanks |
|
|
https://wiki.archlinux.org/index....vice_files http://unix.stackexchange.com/que...or-systemd for example, to sync and adjust system time during boot, simply install and update the ntp package and enable the uptdate.service # systemctl enable ntpdate.service You can read the content of the ntpdate.service file at /usr/lib/systemd/system/ntpdate.service -- [Unit] Description=One-Shot Network Time Service After=network.target nss-lookup.target [Service] Type=oneshot PrivateTmp=true ExecStart=/usr/bin/ntpd -q -g -u ntp:ntp ControlGroup=cpu:/ [Install] WantedBy=multi-user.target -- and I think it has the exact same effect of simply run # ntpd -qg from the command line prompt (one-time only, not really a service). You will have to use cron / cronie on arch if you want to run things at certain time repeatedly (like sync and adjust system time with the ntp time server pool every 12 hours), it's like the scheduled tasks in windows: https://wiki.archlinux.org/index.php/Cron for the old rc.d system, simply put the command or the script in /etc/rc.local: https://wiki.archlinux.org/index....2Frc.local for example, to sync and adjust system time during boot, add the following line to /etc/rc.local ( for rc.d systems): /usr/bin/ntpd -qg // https://wiki.archlinux.org/index....col_daemon // ntpd -qg requires fully updated ntp package |
||
|
|
|
|
thanks so much for the help. i know it can be frustrating helping less experienced/totally ignorant people with this stuff...couldnt have done this without your help. I have everything humming close to perfect now. Quite the feeling of accomplishment learning all this. I will have the server on and ssh into it just to see what other funky stuff i can do with this. Couple of other things i wanted to get working and have been experimenting with: hdparm. downloaded via pacman but hdparm -i and hdparm -y or hdparm -Y dont seem to be working for my external usb enclosure. it says putting drive to sleep/standby but my drive is still humming. Maybe its because its an old program meant to work with ide drives? WOuld be nice to be able to set something up to put my drives to sleep when not in use to save electricity and also keep away extra drive wear and tear. Another thing was i've got everything automounting perfectly for my currently configured drives. But is there a way to get any drive i plug in to automatically be configured as a samba share, instead of explicitly configuring it in smb.conf? sorry we've talked so much abuout automount that i have a feeling of dejavu. were these part of some previous instruction set? |
|
|
is it possible to have a cron job run every 6 hours to remount these shares? seems more like a band-aid solution, but idk any other way to fix this. Code:
0 */6 * * * mount -t nfs4 IP.ADDRESS:/share1 /mnt/share1 |
|
| Thread Tools | Search this Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Keri Lotion: 15-oz Original $4, 15-oz Advanced Lotion or Continuous Moisturization Shea Butter Conditioning Therapy $4.17 + Free Shipping | calistyle | Hot Deals | 0 | 12-03-2012 12:49 AM |
| EMPORIO ARMANI UNISEX AVIATOR SUNGLASSES (BLACK SMOKE OR BROWN) $29.99 + Free Shipping | deals4mykids | Hot Deals | 0 | 11-26-2012 06:06 PM |
| Harmon B Model Aluminum Trumpet Wow-Wow Mute $25.99 + Free Shipping @ wwbw | tedhawkins | Hot Deals | 0 | 11-01-2012 04:18 AM |
| Pink Bead Chandelier Earrings $5 + Free Shipping @ superjeweler | tedhawkins | Hot Deals | 0 | 10-15-2012 05:15 AM |
| Pogoplug Multimedia Sharing Device $25 + Free Shipping | SoupMonster | Hot Deals | 3 | 01-16-2012 06:05 AM |