Root and SSH Access on the Steam Link
Alright this was a lot easier than I expected. Thanks Valve!
After digging through the full 332 update zip I found that Valve left their developer init scripts in /etc/init.d/startup. Not sure if they did this intentionally or not but I like it. So first and foremost I was wrong about the Android AOSP thing, it looks like its just a custom linux and the android stuff I was seeing earlier was just from them using the android signing utility for their updates. Basically they use signapk on their zip files which leaves some android stuff in META-INF. So sorry about the false alarm there.
As for enabling ssh on your Steam Link its very easy. All you need to do is get a pendrive and make this file in these folders: /steamlink/config/system/enable_ssh.txt (Note: the file must have some data in it, if enable_ssh.txt is empty it will not work)
Then reboot the Steam Link with the pendrive inserted, after its done connecting to the network you can ssh into the Steam Link as root with the password `steamlink123`
Have fun!
If you want to dig into it some more look in the /etc/init.d/startup/S01config, in there you can see that you can overwrite any system files or flash a older/custom firmware with a usb pendrive.
After digging through the full 332 update zip I found that Valve left their developer init scripts in /etc/init.d/startup. Not sure if they did this intentionally or not but I like it. So first and foremost I was wrong about the Android AOSP thing, it looks like its just a custom linux and the android stuff I was seeing earlier was just from them using the android signing utility for their updates. Basically they use signapk on their zip files which leaves some android stuff in META-INF. So sorry about the false alarm there.
As for enabling ssh on your Steam Link its very easy. All you need to do is get a pendrive and make this file in these folders: /steamlink/config/system/enable_ssh.txt (Note: the file must have some data in it, if enable_ssh.txt is empty it will not work)
Then reboot the Steam Link with the pendrive inserted, after its done connecting to the network you can ssh into the Steam Link as root with the password `steamlink123`
Have fun!
If you want to dig into it some more look in the /etc/init.d/startup/S01config, in there you can see that you can overwrite any system files or flash a older/custom firmware with a usb pendrive.
What will this eventually enable us to do with the Steam Link? Are you poking around just for the hell of it or do you have something in mind?
ReplyDeleteI want to try and get something like xfce/lxde running on it so we can have a nice WM behind the Big Picture mode.
DeleteAny idea if it's possible to get the Steam Link software running on other ARM hardware?
DeleteCurrently none that I see. It's going to be a fairly difficult task. The easiest way would be to find a developer board with a armv7 CPU and a Vivante GC1000 GPU.
DeleteI just got one for free from Valve's sale, (I used trading card credit) and I want to do something Linux-y with it. It has very similar specs to a Raspberry Pi, and that can browse the web Decently. Have you made any progress with XFCE or LXDE?
DeleteThis comment has been removed by the author.
ReplyDeleteReporting in that after trying this a few times with both a FAT and exFAT formatted drive this does not work. I made sure to completely unplug the power from the Steam Link before inserting the drive and powering it on again.
ReplyDeleteI'm assuming that it is the standard port 22 for ssh access and confirmed in the network settings on the Steam Link that I have the right IP address.
Unless the drive needs to be formatted with a specific filesystem I'm not sure what I've done wrong. Perhaps this was locked down in a recent update?
Any extra information I should know about that might lead to a successful attempt?
Yes the port is 22. I was able to use FAT32 (exFAT) just fine. Have you tried a different pendrive?
DeleteThe latest public build is 345 which I can confirm this still works on, it even still works just fine on dev build 359.
One thing I never though of is I always use the side usb port, maybe the rear ports don't get mounted on boot?
Also make sure you put some data in the enable_ssh.txt file. Anything will do, even just a `1`.
DeleteI've tried different drives and used both the side and back ports and confirmed that the enable_ssh.txt file has content in it.
DeleteEven attempted a factory reset just in case it only worked on an older version. I'm stumped.
Other things I've tried...
DeleteI've tried both GPT and MBR formatted disks. I'm confirmed that the permissions on each directory/file is fully accessible and executable. map scan on the IP of the Steam Link still turns up all closed ports and ssh connections are refused.
I'm running on the public build 345. Haven't attempted wifi yet, but I don't see why that would work over ethernet.
I have a dumb question... when you say, "make this file in these folders: /steamlink/config/system/enable_ssh.txt" that means (on a windows machine) make a folder on the root of the USB drive called steamlink, then a folder inside that called config, then a folder inside that called system; and in THAT folder copy the enable_ssh.txt file.... correct? I tried this with 4 different pen drives in all available USB ports on the link and I cannot get SSH access.
ReplyDeleteThat is correct.
DeleteAre you un-plugging the Link's power before inserting the USB drive?
Just got my Steam Link and I can't seem to be able to get SSH to work. Have tried FAT/FAT32/exFAT and chmod-ing everything. I've double checked that the enable_ssh.txt file has data (the number 1) and that its in the right path. When I try `ssh root@172.31.251.218` it times out. Any hints?
ReplyDeleteFrom that LAN IP I presume you're on a University or some sort of 'Shared' network? If so and you don't have control over the network they may be limiting SSH access. If you can't SSH to something else to test then I'd say your network is just limited. Try plugging the Link and your PC into the same switch or buy a router and NAT it behind your un-managed network: plug both into the router as well.
DeleteMy own home network. I can guarantee that SSH works locally and remotely. I just dug up my old network switch and I'll try that.
DeletePlugged both into the switch and they seem to work now. Strange since none of my other devices or servers seem to have an issue connecting on this network. Thanks for the help though!
DeleteThanks Aaron! I got this working. Formatted pd in fat32 (recreared partition table to be sure there's only one partition from beginning to end, I used MBR), inserted to side usb port while it was powered off. Powered on steamlink, ran portscan targetting steamlink. Voila! 22 port open. I could access root just like OP said. Works on factory build and latest update as well.
DeletePartition type was primary
DeleteVery Interested in this. If anyone figures out how to connect to a tunnel within the steam link via ssh or vpn so I can play games over the internet, please contact me at BetaLeaf@gmail.com
ReplyDeleteFound another override,
ReplyDelete# Note: setting this environment variable is done to prevent having
# PE_Single_CPU come up with one resolution, only to have the shell
# launch and immediately switch resolutions.
RESOLUTION_OVERRIDE_FILE=/mnt/config/system/display_resolution.txt
if [ -f "${RESOLUTION_OVERRIDE_FILE}" ]; then
export PE_USER_DEFAULT_RESOLUTION=$(cat "${RESOLUTION_OVERRIDE_FILE}")
fi
and this one
==> mouse_sensitivity.txt <==
2.1
Still working as of today. I would love to get a Debian distro on it, especially since these are so cheap ($5 atm). It would make a great OpenElec box.
ReplyDeleteKinda Fresh on Linux, so I dont know much about SSH, but did anyone get the chance to do something with the Steam Link, like booting Linux distro, even if it was on an external drive?
ReplyDelete