We have the service started with the dbsvc utility using the -o and -oe options as described here.

For Windows, both options are described in the DCX documentation but they are not part of the Service utility for Linux.

Since the log files seem to be generated fine in the Linux server, are the -o and -oe options not supported for Linux for 12.0.1.3759?

asked 30 Nov '12, 16:33

Derli%20Marcochi's gravatar image

Derli Marcochi
1.6k323877
accept rate: 33%

edited 30 Nov '12, 16:34


Both of those options are server options, not dbsvc options. The dbsvc utility works as follows:

dbsvc [dbsvc switches] -w <name> [server exe] [server switches]

The [server exe] part is not necessary on Unix. Any switch that appears before the -w is a dbsvc switch, meaning that it alters dbsvc's behaviour. Any switch that appears after the -w is a server switch, and dbsvc tells the service to use it. dbsvc itself doesn't know about server switches, which is why -oe is not documented as part of dbsvc.

The confusing part is that on Windows, -o is both a dbsvc switch and a server switch. If the -o switch appears before the -w, dbsvc uses it itself and writes its output there. If it appears after the -w, dbsvc passes it along to the service it creates. The -o switch is not supported by dbsvc on Linux.

You are trying to use the -o and -oe server switches, so they need to appear after the -w. Sorry my answer was so terse before. I hope this clarifies things.

permanent link

answered 30 Nov '12, 18:08

Graeme%20Perrow's gravatar image

Graeme Perrow
8.5k371109
accept rate: 52%

edited 01 Dec '12, 10:18

I am using this command line inside a script to define the service which is creating both log files when started:

/dbsvc -as -s Automatic -t Network -w $service_name -n $server_name -c $mem_alloc -o "$log/olog.txt" -oe "$log/oelog.txt" -os 1M -x $comm_parms "@$netbase/dbfiles.txt"

I can see all the logged info in the olog.txt file until the "Now accepting requests" line so it seems to be correct.

(01 Dec '12, 05:59) Derli Marcochi
Replies hidden

Sorry for my very short answer - I've expanded it. Hopefully it helps.

(01 Dec '12, 07:55) Graeme Perrow

Graeme, could you clarify whether the -o dbsvc modifier option is only supported on Windows (as documented) or applies to Linux, too?

(01 Dec '12, 10:00) Volker Barth
Replies hidden
1

It looks like the Linux version of dbsvc does not support the -o switch. I've updated my answer.

(01 Dec '12, 10:18) Graeme Perrow

@Graeme, as in my command line above, both the -o and -oe switches were placed after the -w as you described.

(01 Dec '12, 12:26) Derli Marcochi
Replies hidden

Yes, I understand. I'm describing how dbsvc works because your original question seemed to be asking why -oe was not documented for dbsvc. I'm explaining that it's not a dbsvc switch at all. The documentation is correct.

(01 Dec '12, 23:51) Graeme Perrow
showing 3 of 6 show all flat view

Well, according to the docs on dbsvc for Windows, -o is also a dbsvc modifier option and gives the possibiliy to log the dbsvc execution itself, so its meaning depends on its position - cf. this sample:

dbsvc -o out1.txt -y -as -w mydsn "%SQLANY12%\bin32\dbsrv12" -n mysrv -o c:\out2.txt

In this case, the output from dbsvc is logged to out1.txt, while the output from the database server is logged to c:out2.txt.

Don't know and can't test whether this is supported on Linux, too - it's not documented there.

Note: In your sample, you are just using -o and -oe as dbsrv12 options - that will work on both platforms.

permanent link

answered 01 Dec '12, 06:13

Volker%20Barth's gravatar image

Volker Barth
30.6k306456663
accept rate: 32%

edited 01 Dec '12, 06:17

1

Yes, we have been using the -o and -oe options for Windows as well. My only concern is that those options are not documented for Linux.

(01 Dec '12, 06:19) Derli Marcochi
Replies hidden

Well, as Graeme and I try to explain: The server options are documented for the according server command (dbsrv12 etc.) and do not apply to dbsvc itself - and therefore don't appear in dbsvc's documention.

(01 Dec '12, 09:58) Volker Barth
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×412
×61
×8

question asked: 30 Nov '12, 16:33

question was seen: 956 times

last updated: 01 Dec '12, 23:51