What does status code 255 mean?


Daniel Mikusa
 

If possible add more logging or increase logging levels. Not sure what
language / runtime you're using, but you might be able to add an exit hook
or some code that is guaranteed to run before your app exits and use that
to dump more info.

If CF were shutting down your app for some reason, you would see a SIGTERM
sent followed by a SIGKILL roughly 10 seconds later (if your app doesn't
gracefully exit first). I don't think that's what is happening here, but
you could catch the SIGTERM and log a message to check. CF would really
only do this if the cell that your app is running on were being shut off
(like during an upgrade). Then it would restart your app automatically on
another cell.

The other case could be that you're exceeding your MEMORY_LIMIT. I don't
think that's happening as I believe Diego logs something that specifically
says when you run out of memory (like `Exited with status 255 (out of
memory)`).

Dan

On Mon, May 2, 2016 at 10:03 AM, Sam Dai <sam.dai(a)servicemax.com> wrote:

No, I didn't see error or related messages in the logs prior to the
application existing. I also executed the command "bosh logs cell_z1 0" to
get the log of cell_z1 0, but didn't find any useful information from the
log.


Sam Dai
 

No, I didn't see error or related messages in the logs prior to the application existing. I also executed the command "bosh logs cell_z1 0" to get the log of cell_z1 0, but didn't find any useful information from the log.


Daniel Mikusa
 

It is the exit status of your application. In other words, your app exited
and returned this number.

http://tldp.org/LDP/abs/html/exit-status.html

It may be an application specific number or it could be one of the exit
codes with a special meaning.

http://tldp.org/LDP/abs/html/exitcodes.html

In this case, it's 255 which is kind of a generic number. Do you see
anything in the logs prior to the application exiting? If not, try turning
up the logging in your application to see if you can figure out what it is
doing prior to exiting.

Dan

On Mon, May 2, 2016 at 4:33 AM, Sam Dai <sam.dai(a)servicemax.com> wrote:

Hello,
I deployed an application to Diego, found this application often got
restarted, there is no error message in the log, just found the following
message, what does the status code 255 mean?

*2016-05-02T14:15:00.06+0800 [CELL/0]* OUT Exit status 255

*2016-05-02T14:15:00.06+0800 [APP/0]* OUT Exit status 255

*2016-05-02T14:15:00.17+0800 [CELL/0]* OUT Creating container

*2016-05-02T14:15:00.66+0800 [CELL/0]* OUT Successfully created
container
*2016-05-02T14:15:43.61+0800 [CELL/0]* OUT Starting health monitoring
of container


CF release version: v235
Diego version: v0.1467.0

Thanks,
Sam


Sam Dai
 

Sorry, the version of CF and Diego in previous mail is incorrect, CF release version is v233, Diego version is V 0.1460.0


Sam Dai
 

Hello,
I deployed an application to Diego, found this application often got
restarted, there is no error message in the log, just found the following
message, what does the status code 255 mean?

*2016-05-02T14:15:00.06+0800 [CELL/0]* OUT Exit status 255

*2016-05-02T14:15:00.06+0800 [APP/0]* OUT Exit status 255

*2016-05-02T14:15:00.17+0800 [CELL/0]* OUT Creating container

*2016-05-02T14:15:00.66+0800 [CELL/0]* OUT Successfully created
container
*2016-05-02T14:15:43.61+0800 [CELL/0]* OUT Starting health monitoring
of container


CF release version: v235
Diego version: v0.1467.0

Thanks,
Sam