[opencms-dev] Antwort: Re: Scheduled Job - java.io.IOException: Permission denied when writing file

Martin.Rosenthal at oerag.de Martin.Rosenthal at oerag.de
Mon Nov 7 12:57:01 CET 2011


Hello,

thanks for your quick answer. I've tested it as suggested. I've can create
a file as user running the appserver.

Regards,
Martin
_______________________________
IT-Anwendungen

Tel.: 0211 529 5775
Fax: 0211 529 59775
Email: Martin.Rosenthal at oerag.de
Internet: www.oerag.de

ÖRAG Rechtsschutzversicherungs-AG
Hansaallee 199, 40549 Düsseldorf
Vorstand: Klaus R. Hartung, Andreas Heinsen
Aufsichtsratsvorsitzender: Ulrich Jansen
Sitz der Gesellschaft: Düsseldorf, Registergericht Düsseldorf HRB 12073

Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte
Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail
irrtümlich erhalten haben, informieren Sie bitte den Absender und
vernichten diese


                                                                           
             Philipp Bühler                                                
             <doublefips at googl                                             
             email.com>                                                 An 
             Gesendet von:              The OpenCms mailing list           
             opencms-dev-bounc          <opencms-dev at opencms.org>          
             es at opencms.org                                          Kopie 
                                                                           
                                                                     Thema 
             07.11.2011 11:05           Re: [opencms-dev] Scheduled Job -  
                                        java.io.IOException: Permission    
                                        denied when writing file           
              Bitte antworten                                              
                    an                                                     
                The OpenCms                                                
               mailing list                                                
             <opencms-dev at open                                             
                 cms.org>                                                  
                                                                           
                                                                           




hello,

if you can, login to AIX, switch to the user running the appserver,
e.g. "su - jboss"
and "cd" to that directory, and try to create a file, e.g. "touch moo.out".
At least any parent directory to the desired one must have
"x"-permissions for that user.

Otherwise talk to your sysadmin about it.

2011/11/7  <Martin.Rosenthal at oerag.de>:
>
> Hello,
>
> i've created a Java-Class which is writing a file in filesystem. It's a
> simple method using
>
> File file = new File(variable with filename);
> file.createNewFile();
>
> The class i'm using as a scheduled job in OpenCMS. On a Windows System
it's
> working fine and a file is generated. But on an AIX Unix System System i
> get an Java exception
>
> java.io.IOException: Permission denied
>        at java.io.File.createNewFile(File.java:894)
>        at de.mwsg.cms.modules.competition.CompetitionDatGenerator.launch
> (CompetitionDatGenerator.java:53)
>        at org.opencms.scheduler.CmsScheduleManager.execute
> (CmsScheduleManager.java:176)
>        at org.quartz.core.JobRunShell.run(JobRunShell.java:203)
>        at org.opencms.scheduler.CmsSchedulerThread.run
> (CmsSchedulerThread.java:123)
>
> But the directory folder, in which the file should be written, has
> permissions for all users to read, write and execute files in it. I think
> the users, under which the scheduled job is executed should be the same
as
> the user of the application server in which OpenCMS is running. Is this
> right? Are there some special conditions to be regarded under Unix?
>
> Thanks and regards,
> Martin Rosenthal
> _______________________________
> IT-Anwendungen
>
> Tel.: 0211 529 5775
> Fax: 0211 529 59775
> Email: Martin.Rosenthal at oerag.de
> Internet: www.oerag.de
>
> ÖRAG Rechtsschutzversicherungs-AG
> Hansaallee 199, 40549 Düsseldorf
> Vorstand: Klaus R. Hartung, Andreas Heinsen
> Aufsichtsratsvorsitzender: Ulrich Jansen
> Sitz der Gesellschaft: Düsseldorf, Registergericht Düsseldorf HRB 12073
>
> Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte
> Informationen. Wenn Sie nicht der richtige Adressat sind oder diese
E-Mail
> irrtümlich erhalten haben, informieren Sie bitte den Absender und
> vernichten diese
>
> _______________________________________________
> This mail is sent to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please
visit
> http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev
>
>
>
>
_______________________________________________
This mail is sent to you from the opencms-dev mailing list
To change your list options, or to unsubscribe from the list, please visit
http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev








More information about the opencms-dev mailing list