LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
Search this Thread
Old 11-13-2007, 01:46 AM   #1
kkpal
Member
 
Registered: Oct 2007
Posts: 101

Rep: Reputation: 15
Question init process


how to set permissions when copy a file to a ntfs partition?
 
Old 11-13-2007, 04:26 AM   #2
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,755

Rep: Reputation: 466Reputation: 466Reputation: 466Reputation: 466Reputation: 466
What does that have to do with the init process?
You can't set permissions on ntfs beacuse it doesn't support those file attributes. You may be able to set the permissions when you copy the file and perhaps have them respected at the moment, but the ownerships and permissions will not 'stick' and once the volume is unmounted and remounted the permissions will be gone. You can use the 'umask' if the volume is mounted in fstab in order to have some control over access.
 
Old 11-15-2007, 11:32 PM   #3
kkpal
Member
 
Registered: Oct 2007
Posts: 101

Original Poster
Rep: Reputation: 15
Lightbulb

Quote:
Originally Posted by gnashley View Post
What does that have to do with the init process?
You can't set permissions on ntfs beacuse it doesn't support those file attributes. You may be able to set the permissions when you copy the file and perhaps have them respected at the moment, but the ownerships and permissions will not 'stick' and once the volume is unmounted and remounted the permissions will be gone. You can use the 'umask' if the volume is mounted in fstab in order to have some control over access.


I want set permission at the time of booting. thats why I want make it part
of init process.
ntfs-3g $MNTPRMS -o silent,umask=0,no_def_opts,allow_other 2>/dev/null
I want to know description of above command.
 
Old 11-16-2007, 03:34 AM   #4
gnashley
Amigo developer
 
Registered: Dec 2003
Location: Germany
Distribution: Slackware
Posts: 4,755

Rep: Reputation: 466Reputation: 466Reputation: 466Reputation: 466Reputation: 466
You need to put those into your /etc/fstab file. Some mount options will only work from the fstab and will do nothing if given from the command line. You should read 'man fstab' and 'man mount' for further info on which mount options are valid with a particular file system and whether they atke effect if given from the command-line or only from fstab.
If you want to try placing the command in some other part of the boot-up process, then the question becomes distro-specific as not all distros handle the init scripts the same way. In Slackware you could put the command in a file called /etc/rc.d/rc.local, but other distros do this significantly different.
 
  


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
Can someone kill INIT process? u4u Linux - General 2 09-15-2014 05:42 PM
attach a process to init sagar.1986 Linux - General 1 04-24-2007 07:01 AM
init Parent Process ID sobia Linux - General 1 06-09-2006 10:28 PM
init process gets stucked prital Linux - Software 0 02-21-2005 05:52 AM
Slackware init process.... hjles Slackware 2 01-30-2003 02:44 PM


All times are GMT -5. The time now is 05:06 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration