protonscr

SteamAPI_IsSteamRunning() failed

steamclosed reviewed
ValveSoftware/steam-for-linux#33 · opened 2012-12-20 by rebl · updated 2013-01-09 · 8 comments · github
1 matching comments, n / p to jump
Rrebl 2012-12-20 github

Some games don't run and throw this message at startup:

[S_API FAIL] SteamAPI_Init() failed; SteamAPI_IsSteamRunning() failed. [S_API FAIL] SteamAPI_Init() failed; unable to locate a running instance of Steam, or a local steamclient.dll.

Apparently they can't find the running Steam instance (I'm launching them from the Steam window, not externally, so there is a Steam instance).

Some games work for me (Uplink), some fail with this error (World of Goo).

I'm using Steam in Debian wheezy amd64 with the nvidia drivers 310.14-1.

EelFarto 2012-12-20 github

I'm getting the same issue with Solar 2 on Fedora 17 (64-bit). I did a bit of digging with strace and found this:

access("/home/stephen/.steampid", F_OK) = 0
open("/home/stephen/.steampid", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0664, st_size=5, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xf4d53000
read(3, "8955\n", 4096)                 = 5
read(3, "", 4096)                       = 0
kill(8955, SIG_0)                       = -1 ESRCH (No such process)
gettimeofday({1356009815, 684687}, NULL) = 0
gettimeofday({1356009815, 684765}, NULL) = 0
readlink("/home/stephen/.steampath", "/home/stephen/.steam/bin32/steam", 4096) = 32
access("/home/stephen/.steampid", F_OK) = 0
open("/home/stephen/.steampid", O_RDONLY) = 4
fstat64(4, {st_mode=S_IFREG|0664, st_size=5, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xf4d52000
read(4, "8955\n", 4096)                 = 5
read(4, "", 4096)                       = 0
kill(8955, SIG_0)                       = -1 ESRCH (No such process)
write(2, "[S_API FAIL] SteamAPI_Init() fai"..., 71) = 71
write(2, "[S_API FAIL] SteamAPI_Init() fai"..., 111) = 111

The /home/stephen/.steampid is linked to /home/stephen/.steam/steam.pid, which appeared to be out of date (had a PID in that didn't relate to any running process).

I closed Steam, deleted steam.pid, started Steam, and Solar 2 will now start (and the steam.pid file now has the correct PID in).

Rrebl 2012-12-21 github

That did it. It would be nice if Steam could delete that file at startup if the PID inside doesn't exist (or isn't a Steam process), but anyway, for my use case I'm adding a rm to my startup script. Thank you.

I'm leaving the bug open so that Valve can implement this "pid cleanup" someday.

Ssofar 2012-12-21 github

Didn't fix the issue for me - problem still persists. Shows in TF2 - the game actually runs but I can't play online or do the training.

Sslouken 2012-12-28 github

We have a fix for this in the next Steam update. Thanks!

?ghost 2013-01-09 github

I'm on open suse, in my case i get wierd looping sym links that point to themselves. I get errors like "/home/sarella/.steam/root/steam.sh: line 106: /home/sarella/.steam/root/ubuntu12_32/steam: Too many levels of symbolic links
". Steam itself runs, and so does TF2, but of course it can't detect if steam instance is running because it's supposed to be able to access .steam directory and check for pid file! I think those loop links are to blame! And more so, i think steam.sh is generating them on lines 61 and 62. I can't fix the file because it's constantly being replaced by updater...

EelFarto 2013-01-09 github

You should comment on issue #118, which is about the the .steam link getting clobbered.

Ppeterfarrell 2013-01-09 github

As of the Jan 8 11:38:03 build of Steam Beta for Linux, I am now seeing this bug when launching TF2. I launched TF2 from the steam clients.

TF2 reports "Steam Beta must be running to make use of Find Servers".

Terminal output says:

[S_API FAIL] SteamAPI_Init() failed; SteamAPI_IsSteamRunning() failed.

I'm also seeing this as well:

/home/peter/.steam/root/steam.sh: line 102: cd: /home/peter/.steam/root: Too many levels of symbolic links
/home/peter/.steam/root/steam.sh: line 106: /home/peter/.steam/root/ubuntu12_32/steam: Too many levels of symbolic links

Jjohndrinkwater 2013-01-09 github

Issue #626 is open for the new build failing with the symlink issue, the solution is to update to the latest steam.deb http://repo.steampowered.com/steam/archive/precise/steam_latest.deb then TF2 and the client is ok.

DLLs