Hi
I am FTPing a file to a remote server from my local server. But after I FTP it the permissions are not in executable option, I need to change the permissions of the FTPed file how can i do that. Below is my script
I tried changing the permission of the remote file but i am not able to do it.
regards
Prashanth
Last edited by zaxxon; 04-01-2010 at 07:11 AM..
Reason: use square brackets instead of pointy ones when using tags ie [] not <>
How do I change IP addresses in command mode? i need to assign custom (non DHCP) addresses from the command line. Actually I also need to know how to change the subnet mask, the gateway and the primary, secondary, ... dns servers. (6 Replies)
Hi All,
If I want to ftp files from machine to local pc. But the ip must change everytime :( (due to VPN), can I write a script to easiler (no need to update ip in script)?
user_name=aaa
password=bbb
cat ip.txt
#
# FTP the files
#
ftp -d -in 199.200.204.109 <<EOF
user $user_name... (2 Replies)
Hi,
I'm uploading files using internet explorer.
1.Open internet explorer 6.0
2.Open site like ftp://172.45.15.1
3.Copy files
The files which I'm copying are basically zip files. What is the default transfer mode, I mean ASCII/BINARY ???.
The problem I'm facing, while extracting these... (4 Replies)
Hi,
One bank statement file should be loaded into some tables by using a concurrent program. But if the file is transfered in binary mode i am getting some special characters in the file which is unexpected. so, for that while moving that file data into tables i want to write a script that... (2 Replies)
Hello All,
On solaris 10 server i could see the FTP service is in maintenance mode always :mad:
Could some assist?
svcs -xv
svc:/network/nfs/nlockmgr:default (NFS lock manager)
State: maintenance since Tue 28 Jul 2009 11:47:55 AM BST
Reason: Restarting too quickly.
See: Sun... (5 Replies)
Hi,
i want to ftp to another server and change the prefix of the file and change direcotry also. but i am unable to get it. any ideas will be helpful?
ftp -n ${HOST} <<END
quote USER $USER
quote PASS $PASS
cd /dir/dir
put file
mv file fnl.fileEND
END (2 Replies)
how to connect to ftp server in passive mode?
ftp server.abc
and how can i see ftp settings, doesn't exist some ftpd.conf
there is some other file where i check the options and configurations of ftp server?
Thanks (3 Replies)
hi,
sorry for posting this for a quick answer.
Is there a one line command to change permissions on files in a directory to a given mode (say 554) and only for those files that do not already have that mode?
Running chmod updates the last access/modified timestamp on the files, and i want to... (11 Replies)
Hi,
How to change mode "drwxrwsr-x+" in directory.
I'm able to set drwxrwsr-x but "+" is difficult to set.
~ $ las -las | grep done1
4 drwxrwsr-x+ 3 root sfuser 4096 Nov 26 16:39 done1
~ $ getfacl done1
# file: done1
# owner: root
# group: sfuser
# flags: -s-
user::rwx... (4 Replies)
First two days of shell scripting... I've looked at awk/sed and man sed only to get off into the weeds of complexity that may not be needed here...
hints for awk or sed or other method to magically change the bolded item below?
Nutshell: HFTST=Y #test mode = true to false & back again so... (0 Replies)
Discussion started by: JeffPGMT
0 Replies
LEARN ABOUT PHP
pharfileinfo.chmod
PHARFILEINFO.CHMOD(3) 1 PHARFILEINFO.CHMOD(3)PharFileInfo::chmod - Sets file-specific permission bits
SYNOPSIS
public void PharFileInfo::chmod (int $permissions)
DESCRIPTION PharFileInfo.chmod(3) allows setting of the executable file permissions bit, as well as read-only bits. Writeable bits are ignored, and set
at runtime based on the phar.readonly INI variable. As with all functionality that modifies the contents of a phar, the phar.readonly INI
variable must be off in order to succeed if the file is within a Phar archive. Files within PharData archives do not have this restriction.
PARAMETERS
o $permissions
- permissions (see chmod(3))
RETURN VALUES
No value is returned.
EXAMPLES
Example #1
A PharFileInfo.chmod(3) example
<?php
// make sure it doesn't exist
@unlink('brandnewphar.phar');
try {
$p = new Phar('brandnewphar.phar', 0, 'brandnewphar.phar');
$p['file.sh'] = '#!/usr/local/lib/php
<?php echo "hi"; ?>';
// set executable bit
$p['file.sh']->chmod(0555);
var_dump($p['file.sh']->isExecutable());
} catch (Exception $e) {
echo 'Could not create/modify phar: ', $e;
}
?>
The above example will output:
bool(true)
PHP Documentation Group PHARFILEINFO.CHMOD(3)