[opencms-dev] Antwort: Re: Antwort: Re: 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 14:43:31 CET 2011
Hello everybody,
thanks for your help. I've found the error. It was really wrong path. I've
used a path for a temporary file, we're i haven't any access rights on
Unix.
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
"Lammersdorf,
Lorenz"
<ll at metrohm.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 13:26 Re: [opencms-dev] Antwort: Re:
Antwort: Re: Scheduled Job
-java.io.IOException:Permission
Bitte antworten denied when writing file
an
The OpenCms
mailing list
<opencms-dev at open
cms.org>
as I wrote, might be a dumb question :)
then I think philipp is right and your class works in the wrong path.
probably you forgot the / at the first or last position of your path name
string?
-----Ursprüngliche Nachricht-----
Von: opencms-dev-bounces at opencms.org [
mailto:opencms-dev-bounces at opencms.org] Im Auftrag von
Martin.Rosenthal at oerag.de
Gesendet: Montag, 7. November 2011 13:17
An: The OpenCms mailing list
Betreff: [opencms-dev] Antwort: Re: Antwort: Re: Scheduled Job
-java.io.IOException:Permission denied when writing file
Hello,
yes because the class file is invoked by schedule manager of OpenCMS. The
exception ist happened when executing the java.File-method createNewFile()
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
"Lammersdorf,
Lorenz"
<ll at metrohm.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 13:12 Re: [opencms-dev] Antwort: Re:
Scheduled Job -
java.io.IOException:Permission
Bitte antworten denied when writing file
an
The OpenCms
mailing list
<opencms-dev at open
cms.org>
might be a dumb idea, but is the app user allowed to read the class file?
-----Ursprüngliche Nachricht-----
Von: opencms-dev-bounces at opencms.org [
mailto:opencms-dev-bounces at opencms.org] Im Auftrag von Philipp Bühler
Gesendet: Montag, 7. November 2011 13:04
An: The OpenCms mailing list
Betreff: Re: [opencms-dev] Antwort: Re: Scheduled Job -
java.io.IOException:Permission denied when writing file
Then my best guess is that the application or app-server is trying a
different directory than you think it does :)
Maybe you add some logging to your app.. e.g. "trying to write to
DIR/FILE" - including full-path of course.
2011/11/7 <Martin.Rosenthal at oerag.de>:
> 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
>
>
>
>
>
> _______________________________________________
> 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
_______________________________________________
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
_______________________________________________
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