f



"Permission denied to create file" message from untar

I'm using Matlab's untar and I keep getting the message: "Warning: Permission denied to create file "foo.bar".  The error comes from line 106 in extractArchive.m, and according to the comments in that m-file, this means that "the file is trying to be written into a directory with insufficient privileges."  Anyone know how to fix this in Windows XP and Matlab 7.4?  I'm the administrator with full permissions, so I'm not sure why Matlab is unable to create a directory that it can write to.  It might have something to do with the fact that files and directories within the tar archive are read only, or at least they were on the Linux machine where the tar archive was made.


0
andrew732 (3)
10/31/2008 3:33:01 AM
comp.soft-sys.matlab 211266 articles. 17 followers. lunamoonmoon (258) is leader. Post Follow

2 Replies
778 Views

Similar Articles

[PageSpeed] 48

Andy Yancy wrote:
> I'm using Matlab's untar and I keep getting the message: "Warning: Permission denied to create
> file "foo.bar".  The error comes from line 106 in extractArchive.m, and according to the
> comments in that m-file, this means that "the file is trying to be written into a
> directory with insufficient privileges."  Anyone know how to fix this in Windows XP
> and Matlab 7.4?  I'm the administrator with full permissions, so I'm not sure why
> Matlab is unable to create a directory that it can write to.  It might have something
> to do with the fact that files and directories within the tar archive are read only,
> or at least they were on the Linux machine where the tar archive was made.

Yes, if the tar archive contains the entry for the directory before the entry for
some file in that directory, then the code in the file you referred to will set
the directory to read only before it gets around to processing the files.
That's why, in creating a tar archive, it is common to use  find -depth
and pipe the names into tar, so that the directory entries do not appear in the
stream until -after- the directory entries that will get written in to them.
This is one of the (several) things that cpio improved on over tar.

-- 
..signature note: I am now avoiding replying to unclear or ambiguous postings.
Please review questions before posting them. Be specific. Use examples of what you mean,
of what you don't mean. Specify boundary conditions, and data classes and value
relationships -- what if we scrambled your data or used -Inf, NaN, or complex(rand,rand)?
0
roberson (2980)
10/31/2008 6:45:07 AM
Walter Roberson <roberson@hushmail.com> wrote in message <FPxOk.82$gD3.66@newsfe01.iad>...
> Andy Yancy wrote:
> > I'm using Matlab's untar and I keep getting the message: "Warning: Permission denied to create
> > file "foo.bar".  The error comes from line 106 in extractArchive.m, and according to the
> > comments in that m-file, this means that "the file is trying to be written into a
> > directory with insufficient privileges."  Anyone know how to fix this in Windows XP
> > and Matlab 7.4?  I'm the administrator with full permissions, so I'm not sure why
> > Matlab is unable to create a directory that it can write to.  It might have something
> > to do with the fact that files and directories within the tar archive are read only,
> > or at least they were on the Linux machine where the tar archive was made.
> 
> Yes, if the tar archive contains the entry for the directory before the entry for
> some file in that directory, then the code in the file you referred to will set
> the directory to read only before it gets around to processing the files.
> That's why, in creating a tar archive, it is common to use  find -depth
> and pipe the names into tar, so that the directory entries do not appear in the
> stream until -after- the directory entries that will get written in to them.
> This is one of the (several) things that cpio improved on over tar.
> 
> -- 
> .signature note: I am now avoiding replying to unclear or ambiguous postings.
> Please review questions before posting them. Be specific. Use examples of what you mean,
> of what you don't mean. Specify boundary conditions, and data classes and value
> relationships -- what if we scrambled your data or used -Inf, NaN, or complex(rand,rand)?

OK, thanks Walter.  Does that mean the only thing I can do is remake the tar file?


0
andrew732 (3)
10/31/2008 8:18:02 AM
Reply:

Similar Artilces:

Method of suppressing "Permission denied" messages during "find" command ?
I can start a find command similar to find / -name "dummy" -print and it will find all files. However a lot of files were listed with the remark "Permission denied" and similar other warnings. How can I suppress these messages? George -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 George Dainis wrote: > I can start a find command similar to > > find / -name "dummy" -print > > and it will find all files. However a lot of files were listed with the remark > "Permission denied" and similar other warnings. > > How can I suppress these messages? One way would be to redirect stderr to /dev/null As in find / -name "dummy" -print 2>/dev/null - -- Lew Pitcher, IT Specialist, Corporate Technology Solutions, Enterprise Technology Solutions, TD Bank Financial Group (Opinions expressed here are my own, not my employer's) -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.3 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFEgEaLagVFX4UWr64RAjkBAKDvUAmvsxrcBIGEYOua/8KZsO1vkgCeKDum M34RNMgaKmHPLMX6A9kYbNg= =r98L -----END PGP SIGNATURE----- George Dainis wrote: > I can start a find command similar to > > find / -name "dummy" -print > > and it will find all files. However a lot of files were listed with the remark > "Permission denied" and similar other warnings. > > How can I suppress these messages? I would assume (alt...

How to create a file named "\a" and "-a"
Hi !How to create a file named "\a" and "-a"? dolphin wrote: > Hi !How to create a file named "\a" and "-a"? > "touch \\a" nets you "\a" making "-a" filename is harder.. You may have to resort to C code.. Its pretty hard to get the standard tools to ignore what they interpret as switches. On 16 Mar 2007 at 14:36, dolphin wrote: > Hi !How to create a file named "\a" touch '\a' > and "-a"? touch -- -a (assuming GNU touch) -- email: echo t.adllkhsl@iypzavs.hj.br | tr a-gh-pq...

Got "permission denied" when creating a posix message queue.
Below code is the excise from Unix network programming: IPC. But after building the code using : g++ thisfile.cpp -lrt running: a.out /tmp/mq.1234 will cause the code print "errno=13 Permission denied". How to solve this issue? Thank you! #include <mqueue.h> #include <errno.h> #include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <string.h> #include <sys/stat.h> #define FILE_MODE S_IRUSR|S_IWUSR int main(int argc, char** argv){ int c, flags; mqd_t mqd; flags = O_RDWR|O_CREAT; while( ( c = getopt(argc, argv, "e" ) ) != -1 ){ switch (c){ case 'e': flags |= O_EXCL; break; } } if( optind != argc - 1 ){ printf("usage: mqcreate [ -e ] <name>"); return -1; } printf("FILE_MOED=%d\n", FILE_MODE); mqd = mq_open( argv[optind], flags, FILE_MODE, NULL); printf("The message queue d: %d \n", mqd); printf("%d :%s \n", errno, strerror(errno)); mq_close(mqd); exit(0); } Hill wrote: > Below code is the excise from Unix network programming: IPC. > > But after building the code using : g++ thisfile.cpp -lrt > running: a.out /tmp/mq.1234 will cause the code print "errno=13 Hello! Try this: ../a.out -e /mq.1234 and use the following commands to see your new MQ: olimpico_work ~ # mkdir /dev/mqueue olimpico_work ~ # mount -t mqu...

"Message Exchange" and "File Format"
Message Exchange dicom file (online networking) have a dicom upper layer, and File Format dicom files (for media storage interchange offline) don't. Is there a way of converting on to another? Do I understand this right, are there two type of dicom files? For example Matlab will only accept File Format files. Thanks. Barbara wrote: > Message Exchange dicom file (online networking) have a dicom upper > layer, and File Format dicom files (for media storage interchange > offline) don't. Is there a way of converting on to another? Do I > understand this right, are there two type of dicom files? There is only a single DICOM file format. When DICOM messages are transmitted over a network, DICOM uses a network protocol that splits large data sets into multiple fixed-length packets, so-called protocol data units (PDUs). DICOM part 8 defines the format and content of these PDUs and a finite state machine (the so-called DICOM Upper Layer for TCP/IP) that implements the network protocol. This sequence of PDUs, however, is not used (and not intended) for file storage. Regards, Marco Eichelberg Hi Barbara As Marco says, there is only a single file format officially (defined in part 10), and that is a file with a 128 byte preamble and "DICM" and then a meta information header that defines the transfer syntax in which the data set is encoded. Unfortunately, some folks are still in the habit of just capturing a dataset o...

Caught "std::exception" Exception message is: Message Catalog MATLAB:FileIO was not loaded from the file. Please check file location, format or contents
Can any one help on this error please. As i am using many files Caught "std::exception" Exception message is: Message Catalog MATLAB:FileIO was not loaded from the file. Please check file location, format or contents Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at com.mathworks.mlwidgets.workspace.ClassicWhosInformation.<init>(ClassicWhosInformation.java:20) at com.mathworks.mlwidgets.workspace.ClassicWhosInformation.getInstance(ClassicWhosInformation.java:38) at com.mathworks.mlwidgets.workspace.WhosRecordlistModel.setWhosInform...

"out" and "in out"
Hi i found the following explaination: In Ada, "in" parameters are similar to C++ const parameters. They are effectively read-only within the scope of the called subprogram. Ada "in out" parameters have a reliable initial value (that passed in from the calling subprogram) and may be modified within the scope of the called procedure. Ada "out" parameters have no reliable initial value, but are expected to be assigned a value within the called procedure. What does "have no reliable initial value" mean when considering the "out" parameter? By chance I created a small program as follows: =========== s : string := "CAT"; procedure modify ( s1 : out string ) is begin s1(2) := 'U'; end modify; ... put ( modify(s) ); =========== now I get as a result "CUT", and i dont understand why i get this result. Doesnt the "out" specify that its initial value isnt passed in via the parameter? But it seems to be passed in the above. In fact the "out" is acting like an "in out". I am a little confused. Could someone shed some light on this? Many thanks! zork "zork" <zork@nospam.com> wrote in message news:4104d5de@dnews.tpgi.com.au... > Hi i found the following explaination: > > In Ada, "in" parameters are similar to C++ const parameters. They are > effectively read-only within the scope of the called subprogram. > Ada "in out&q...

why "::", not "."
Why does the method of modules use a dot, and the constants a double colon? e.g. Math::PI and Math.cos -- Posted via http://www.ruby-forum.com/. On Oct 26, 2010, at 01:48 , Oleg Igor wrote: > Why does the method of modules use a dot, and the constants a double > colon? > e.g. > Math::PI and Math.cos For the same reason why inner-classes/modules use double colon, because = they're constants and that's how you look up via constant namespace. Math::PI and ActiveRecord::Base are the same type of lookup... it is = just that Base is a module and PI is a float....

about "++" and "--"
why this program snippet display "8,7,7,8,-7,-8" the program is: main() { int i=8; printf("%d\n%d\n%d\n%d\n%d\n%d\n",++i,--i,i++,i--,-i++,-i--); } > why this program snippet display "8,7,7,8,-7,-8" Ask your compiler-vendor because this result is IMHO implementation-defined. Check this out: http://www.parashift.com/c++-faq-lite/misc-technical-issues.html#faq-39.15 http://www.parashift.com/c++-faq-lite/misc-technical-issues.html#faq-39.16 Regards, Irina Marudina fxc123@gmail.com wrote: > why this program snippet display "8,7,7,8,-7,-8&q...

Changing case "message" to "MESSAGE"
Working my way through Koenig & Moo "Accelerated C++" and using Borlang Builder 5 (but that is probably not relevant) I reached exercise 1-1 and typed in #include <vcl.h> #pragma hdrstop #include <iostream> #include <string> int main(int argc, char*argv[]} { const std::string hello = "Hello" // This by itself compiled const std::string message = "Hello" // and other stuff which I have //left out here. system("PAUSE"); return 0; } But I left caps lock on, and by mistake typed MESSAGE, an...

"mailutil transfer" spews "Permission denied" errors
I'm intending to use `mailutil' from the IMAP Toolkit to copy several thousand IMAP mailboxes from one Cyrus server to another. In my tests, `mailutil transfer' works, but it generates a stream of `Permission denied' errors. I assume these occur because the source folders are opened read-only, but the server is attempting to set flags there. Is there a way to prevent the attempt, or at least to suppress the errors? -- -Gary Mills- -Unix Support- -U of M Academic Computing and Networking- On Wed, 27 Jan 2005, Gary Mills wrote: > I'm intending to use `mailutil' from the IMAP Toolkit to copy > several thousand IMAP mailboxes from one Cyrus server to another. > In my tests, `mailutil transfer' works, but it generates a stream > of `Permission denied' errors. I assume these occur because the > source folders are opened read-only, but the server is attempting > to set flags there. Is there a way to prevent the attempt, or at > least to suppress the errors? "Permission denied" is coming from the server. "mailutil transfer" doesn't attempt to set any flags in the source mailboxes. I suggest that you use the -debug and -verbose flags to find out why the server is saying "Permission denied". It may not, in fact, actually be copying any mailboxes. -- Mark -- http://staff.washington.edu/mrc Science does not emerge from voting, party politics, or public debate. Si vis pacem, para ...

"brctl" command not working, how to create "brctl" file?
I need to configure Linux machine as bridge, how can I create "brctl" command?. Thanks. On 4 Jun 2005 14:52:04 -0700, santa19992000@yahoo.com <santa19992000@yahoo.com> wrote: > I need to configure Linux machine as bridge, how can I create "brctl" > command?. > apt-get install bridge-utils (if you use Debian or you have installed apt) -- Depend on the rabbit's foot if you will, but remember, it didn't help the rabbit. -- R.E. Shay ...

Urgent need """""""""""INFORMATICA DEVELOPER"""""""""""""
Hello Partners, How are you ? Please find the requirements below. Title: Database/ETL Developer Duration: 6 months Location: NY Exp: 7+ Locals preferred Database/ETL requirements (Mandatory) Candidate must have worked with financial instruments, preferably Mutual Funds but, Equities are also ok. PL/SQL - packages, Stored procs, Functions, Aggregate functions, Pipelined Functions Informatica 8.6 - especially complex mappings, complex maplets, complex workflows, transformations Oracle 10g/11g Unix/Linux shell scripting Database/ETL requirements (Optional) Data warehousing experience Threading and job concepts in 10g/11g Cost based Optimizer concepts in 10g/11g Must : Experience with XML files and partitioning concepts in Oracle, Collections, Material Views Note : No phone calls please. : send Resumes to karthik@bhaninfo.com Thanks & Regards Karthik BhanInfo karthik@bhaninfo.com ...

files "." and ".." from readdir()
Will readdir always return "." and ".." as the _first_ two entries returned if the filesystem has them? I'm just curious if it testing for them can be skipped after the first two have been tested. I've always written my loops around readdir with the tests applied in every case. -- |WARNING: Due to extreme spam, googlegroups.com is blocked. Due to ignorance | | by the abuse department, bellsouth.net is blocked. If you post to | | Usenet from these places, find another Usenet provider ASAP. | | Phil Howard KA9WGN (email for humans: first ...

"In" "Out" and "Trash"
I just bought a new computer and I re-installed Eudora Light on my new computer. But when I open Eudora, the "In", "Out" and "Trash" links are not on the left side of the screen the way they were on my old computer. How can I get these links back on the left side of the screen? Thank you. On 25 Mar 2007 09:49:22 -0700, "abx" <abfunex@yahoo.com> wrote: >I just bought a new computer and I re-installed Eudora Light on my new >computer. But when I open Eudora, the "In", "Out" and "Trash" links >are ...

Total confusing "Permission denied" message
I need to set up a service account that will be used by some DBAs after my contract is done. I built and tested everything in my personal account and now I'm moving everything to the service account. Unfortunately, commands that were working perfectly are now failing. I've even tried copying all of my .ssh files to the service account, and that also fails. I've run both client commands with three '-v' options and included the 'diff' below. Can anyone thing of anything I'm missing, or even a good "next step"? Thanks. example|global$ uname -a SunOS example 5.10 Generic_127111-06 sun4v sparc SUNW,Sun-Fire-T200 example|global$ ssh -l samwyse -o PreferredAuthentications=publickey localhost echo hi hi example|global$ ssh -l symcli -o PreferredAuthentications=publickey localhost echo hi Permission denied (gssapi-keyex,gssapi-with- mic,publickey,password,keyboard-interactive). example|global$ ls -al ~symcli/.ssh total 292 drwxr-xr-x 2 symcli unix 512 Oct 30 20:39 . drwxrwxr-x 5 symcli root 512 Nov 2 20:36 .. -rw-r--r-- 1 symcli unix 61060 Aug 21 20:03 authorized_keys -rw------- 1 symcli unix 668 May 27 18:59 id_dsa -rw-r--r-- 1 symcli unix 608 May 27 18:59 id_dsa.pub -rw------- 1 symcli unix 883 May 27 18:59 id_rsa -rw-r--r-- 1 symcli unix 228 May 27 18:59 id_rsa.pub -rw-r--r-- 1 symcli unix 71926 Sep 23 20:37 k...

CONVERTING a ".sas" file into ".dat" file
hello , i use the codes first to import from excel and second to convert from .xls to .sas format .But I need to have the data in .dat format.Kindly guide :- (1) PROC IMPORT OUT= WORK.MARCH DATAFILE= "c:\Sas\MARCH.xls" DBMS=EXCEL REPLACE; SHEET="march$"; GETNAMES=YES; MIXED=NO; SCANTEXT=YES; USEDATE=YES; SCANTIME=YES; RUN; (2) * convert the excel file into a SAS data file and put it into a directory "c:\Sas"* libname dis "c:\Sas"; proc import datafile="C:\Cwa\laptop_review.xls" out=dis.sales replace; run ; regards , markc On 2 Mar, 09:58, mark <mark.chas...@yahoo.in> wrote: > hello , > > i use the codes first to import from excel and second to convert > from .xls to .sas format .But I need to have the data in .dat > format.Kindly =A0guide :- > > (1) > =A0 =A0 =A0 =A0 =A0PROC IMPORT OUT=3D WORK.MARCH > =A0 =A0 =A0 =A0 =A0 =A0 DATAFILE=3D "c:\Sas\MARCH.xls" > =A0 =A0 =A0 =A0 =A0 =A0 DBMS=3DEXCEL REPLACE; > =A0 =A0 =A0SHEET=3D"march$"; > =A0 =A0 =A0GETNAMES=3DYES; > =A0 =A0 =A0MIXED=3DNO; > =A0 =A0 =A0SCANTEXT=3DYES; > =A0 =A0 =A0USEDATE=3DYES; > =A0 =A0 =A0SCANTIME=3DYES; > RUN; > > (2) > =A0 =A0 =A0 =A0* convert the excel file into a SAS data file and put it i= nto a > directory "c:\Sas"* > libname dis ...

Does Python have equivalent to MATLAB "varargin", "varargout", "nargin", "nargout"?
Thank you in advance for your response. Dmitrey openopt@ukr.net writes: > Thank you in advance for your response. And those do ... ? -- Jorge Godoy <jgodoy@gmail.com> Where you would use varargin and nargin in Matlab, you would use the *args mechanism in Python. Try calling def t1(*args): print args print len(args) with different argument lists Where you would use varargout and nargout in Matlab you would use tuple unpacking in Python. Play with this def t2(n): return tuple(range(n)) a, b = t2(2) x = t2(3) On Feb 18, 12:58 pm, open...@ukr.net wrote: > Th...

How to create a java "extends"/"implements" clause with xsd file and castor?
I hate to start the email with the "I'm new to this clause", but there it is. I am understanding how the xsd files work and how the castor SourceGenerator works. What I am not understanding is how the binding of a complexType to another package in java works. Basically I have in my .xsd file: <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified"> .. .. .. <xs:element name="my-Operation"> <xs:annotation> <xs:documentation>Root element</xs:documentation> </xs:annotation> <xs:complexType> <xs:complexContent> <xs:all> <xs:element ref="my-Login" minOccurs="0"/> <xs:element ref="my-Logoff" minOccurs="0"/> </xs:all> </xs:complexContent> </xs:complexType> </xs:element> (I understand I am missing the binding stuff, but I feel as though what I have attempted is completely wrong so I will save you all the pain...) What I would like to get is: public class MyOperation implements com.myother.package.MyInterface, java.io.Serializable { .... } Heck, at this point, I would forget the interface and use another class instead: public class MyOperation extends com.myother.package.MyClass implements java.io.Serializable { .... } The extends/implements clauses are what I can not figure ...

"version 6.5"-reading of "version 7"-created MAT files
undefined Akshaya Trivedi: <SNIP cannot load r14+ mat in and up to r13+ evergreen... a hint: in r14+ save your data with the <-v6> flag, eg, save('foo','mydata','-v6'); -or- in the command window's tab, mouse down to and click the: -> files -> preferences -> general -> mat-files -> ensure backward compatibility (-v6) option us ...

Re: CONVERTING a ".sas" file into ".dat" file
hi ... just one suggestion (addition) to the code put _all_; writes values preceded by the variable names, plus the SAS automatic variables data _null_; set sashelp.class (obs=2); put _all_; run; Name=Alfred Sex=M Age=14 Height=69 Weight=112.5 _ERROR_=0 _N_=1 Name=Alice Sex=F Age=13 Height=56.5 Weight=84 _ERROR_=0 _N_=2 make one addition ... data _null_; set sashelp.class (obs=2); put (_all_) (:); run; Alfred M 14.0 69.0 112.5 Alice F 13.0 56.5 84.0 and another idea ... if you want the data aligned in columns ... data _null_; set sashelp.class (obs=2); pu...

why construct file with "", the path of the file return "/"? 364127
l am a little puzzled, why the file's behavior like this: File fl = new File("","1.txt"); System.out.println(fl.getName()); System.out.println(fl.getParent()); System.out.println(fl.getPath()); System.out.println(fl.getAbsolutePath()); try { System.out.println(fl.getCanonicalPath()); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } ...

What is a "File URL" as opposed to a "non-file URL"
Hi, Sorry to be thick, but what is a "File URL"? Looking on the web, the closest I got to it was a URL that literally starts with "File:"; is that correct? The reason I ask is that I'm looking at IE Java security settings in my IE browser and it says that "Connect to non-file url codebase" is OK but "File Based" is disabled. As I hope to have the flexibility to use a subset of FTP as the protocol to upload my Applets from VMS I am hoping that "File Based" does mean "file:" and does not pertain to FTP vs HTTP. Does it just mean &...

interface "Matlab" with "Ansys" ??
Did any body know how to interface "Matlab" with "Ansys" ?? I am having matlab optimization code. but,how to interface it with ANSYS I don't no. pl,guide me to solve my problem . with regards Sampath Kumar L Mob :- 9591488258 "Sampath Kumar" <samathkmr.ln@gmail.com> wrote in message <ilkgbg$i5v$1@fred.mathworks.com>... > Did any body know how to interface "Matlab" with "Ansys" ?? I am having matlab optimization code. but,how to interface it with ANSYS I don't no. pl,guide me to solve my problem . > > with regard...

Removing ".." and "." from a file path
I only found the "File.expand_path" function to make a relative into an absolute path, but what about the ".." and "." components. I need a canonical version of a file path, so a function that would also remove adjacent '/' or '\' and transform to the corresponding OS path separator would be the best. Is there anything like this available ? ...

Web resources about - "Permission denied to create file" message from untar - comp.soft-sys.matlab

Resources last updated: 3/28/2016 8:29:48 PM