file-permissions

File system is not writable

放肆的年华 提交于 2019-11-28 10:27:00
问题 I installed Drupal 7 in a web host successfully. After installing a module, I got an error errors and and status report gave me this error message: File system Not writable The directory /Applications/MAMP/tmp/php does not exist. You may need to set the correct directory at the file system settings page or change the current directory's permissions so that it is writable. I check the permissions for (sites/default/files) and it has 755 permissions and I change it to 777 but nothing happened

Windows Service can't access network share

爱⌒轻易说出口 提交于 2019-11-28 09:47:20
I have a windows service running on my local machine. It's configured to run under NT AUTHORITY\NETWORK SERVICE. The program access a network shared drive on a computer in the same subnet. That shared directory has Everyone set to Full control. I'm getting False on File.Exists, but the file exists. I'm certain this is a permission issue. Am I forgetting anything? Note, the computer with the shared drive is not on a domain. Brian T Solution was found here: https://serverfault.com/questions/177139/windows-service-cant-access-network-share The fact that the machine with the shared drive is not on

programatically removing “Include inheritable permissions from this object's parent” checkbox using C#

烈酒焚心 提交于 2019-11-28 09:33:01
问题 I have a requirement in my application to iterate through all the sub-folders programatically removing "Include inheritable permissions from this object's parent" check box using C#. And also convert and add the inherited parent permissions as explicit permissions on the folder. Can any one let me know ? how can i do it in C#. 回答1: You need to use ObjectSecurity.SetAccessRuleProtection: string path = @"..."; FileSecurity fs = File.GetAccessControl(path); fs.SetAccessRuleProtection(true, false

Nodejs File Permissions

旧城冷巷雨未停 提交于 2019-11-28 08:17:25
In Node the fs.stat method returns an fs.Stats object right, and I can get the file permission through the fs.Stats.mode property. Here is a real output from both node and shell for the same directories: node shell 17407 d rwx rwx rwt 16877 d rwx r-x r-x 16749 d r-x r-x r-x 16832 d rwx --- --- I need to know how to parse the fs.Stats.mode number to get the permissions. Answer The number is in octal numeric system, after converting to decimal looks like this: 17407 41777 d rwx rwx rwt 16877 40755 d rwx r-x r-x 16749 40555 d r-x r-x r-x 16832 40777 d rwx --- --- And the convertion from octal to

POSIX shared memory and semaphores permissions set incorrectly by open calls

。_饼干妹妹 提交于 2019-11-28 05:44:45
问题 I'm trying to create a shared memory which will be used by several processes, which will not necessarily be started by the same user, so I create the segment with the following line: fd = shm_open(SHARE_MEM_NAME,O_RDWR | O_CREAT,0606); however, when I check out the permissions of the file created in /dev/shm they are: -rw----r-- 1 lmccauslin lmccauslin 1784 2012-08-10 17:11 /dev/shm/CubeConfigShare not -rw----rw- as I'd expected. the permissions for /dev/shm are lrwxrwxrwx. The exact same

Recursively chmod/chown/chgrp all files and folder within a directory

时间秒杀一切 提交于 2019-11-28 03:48:08
问题 I am working on a site which builds other sites. Some if it I use copy() to create the files and directories, other times I'm building XML files in php and using DOMDocument::save to save them. The end result is a root folder with all sorts of messed up permissions. I've beening modding files and folders as I go, which words to some extent, but I'm particularly having trouble when it comes to using copy() . (This is where I'm at so far http://pastebin.com/SBE8vtFX, attn: function modPath(

PowerShell folder permission error - Some or all identity references could not be translated.

ぐ巨炮叔叔 提交于 2019-11-28 03:07:43
问题 I have read many posts about this, but I still can't get it. I am running this script as Admin and It does create the folders requred, just does not set the appropriate permissions. Any help would be appreciated. Thank you! $Users = Get-Content "D:\New_Users.txt" ForEach ($user in $users) { $newPath = Join-Path "F:\Users" -childpath $user New-Item $newPath -type directory $UserObj = New-Object System.Security.Principal.NTAccount("DOMAIN",$user) $acl = Get-Acl $newpath $acl

Mercurial: Ignore file permission / mode (chmod) changes

我只是一个虾纸丫 提交于 2019-11-28 01:05:12
Is there a way to ignore file permission / mode (chmod) changes for a Mercurial repository? I'm looking for a setting similar to Git's: core.filemode -> false as described here: Can I make git diff ignore permission changes Update: the correct answer is Ry4an's together with my second comment to his answer. Ry4an Brase Mercurial only tracks the execute permission on files and not in a user/group/other way, just as a single bit, so depending what you're trying to squelch it's possible you really need to just adjust the umask of the user running hg update ' If it is the execute bit that's

Is possible to set System DateTime from my Android App?

孤街浪徒 提交于 2019-11-28 00:48:01
I want to set system clock by SystemClock.setCurrentTimeMillis , but met following error: "Unable to open alarm driver: Permission denied" Below is the Description of setCurrentMillis API from Android Developers Site: public static boolean setCurrentTimeMillis (long millis) Since: API Level 1 Sets the current wall time, in milliseconds. Requires the calling process to have appropriate permissions. Returns if the clock was successfully set to the specified time. So, Application Needs to obtain the Permission to set the time. In AndroidManisfest.xml I inserted android.permission.SET_TIME but I

Taking ownership of files with 'broken' permissions

拟墨画扇 提交于 2019-11-27 22:26:02
I'm trying to overcome the following situation. Given a directory stored on an NTFS volume, where: The directory owner is set to someone else (a non-privileged user for example) The directory DACL is configured to permit access to a specific group of people that does not include the system or Administrators The DACL on the directory actually grants no one access to either take ownership or change the DACL (or in short, the all administrators have been locked out of the folder) But! The account I am running under has administrative rights (SeBackupPrivilege, SeSecurityPrivilege) The existing