Has anyone successfully installed RStudio Server on OpenSUSE?

For a few days I have been trying to find some more info on installing RStudio server (RStudio) on my OpenSUSE 12.1 64-bit computer, but found no comprehensive suggestions (I dare not say tutorial). I was able to install the desktop version rpm, and it worked, but I really need is the server edition, so I can use it remotely through a browser without X forwarding, etc. I was considering source compilation, but that seems to need a lot of development dependencies, plus one from OpenJDK. As I have the Sun Java installed, I am concerned that may “destroy” something on my system. I further ran into alleged issues b/w cmake and checkinstall (as I would ideally like an rpm to install via zypper), so if anyone could offer any insight into the compatibility of the latter, that would be great.

I see the RStudio website offers an rpm for Fedora, which is allegedly incompatible with OpenSUSE, and the support forums over the RStudio site seem to assume prior knowledge superior to my own, so I am stuck.

So if someone has successfully installed RStudio server on their OpenSUSE system, please share how you did it. Thanx in advance!

I saw your post, and although I’d never installed RStudio server, and I’m not much of a Linux guru, I’ve been interested in learning R and figured I’d give installing RStudio server a shot. I fired up VirtualBox and tried it out. You’ll be happy to know that I got it working without much fuss and no need to compile. This result helps prove my theory that I can solve everyone’s problems except my own. :slight_smile: It seems to be working; I was able to connect with a browser on the same machine as the server, log in, and got the main screen that looked just like a screenshot on the webpage with no errors or issues. Since it’s rather late here and I want to do it once more to be sure I’ve got the steps clear, I’ll make a detailed post sometime tomorrow for you about what to do. There was about 6 or 7 things I needed to do to get the Red Hat RPM working on OpenSUSE 12.1 64-bit, including creating three symlinks, editing a config file and adding a user to a group.

Ok, here’s what I did:

  1. Download the Red Hat rpm of the server install from RStudio’s web page.

  2. Install R-base from the OpenSUSE repositories.

  3. Install the Red Hat RStudio server rpm with "zypper in " plus the path/filename. Zypper will complain that nothing satisfies libcrypto.so.6; tell it to continue the install and break the dependencies.

  4. Type the following commands as root:
    ln -s /lib64/libcrypto.so.1.0.0 /usr/lib64/libcrypto.so.6
    ln -s /lib64/libssl.so.1.0.0 /usr/lib64/libssl.so.6
    ln -s /usr/lib64/libgfortran.so.3 /usr/lib64/libgfortran.so.1

  5. As root, open the file /etc/init.d/rstudio-server with a text editor.

  6. About seven lines down there’s a line that reads “./etc/rc.d/init.d/functions”. Place the pound sign # in front of that line to comment it out. Alternately, you can delete the line.

  7. About another 11 lines down there is the line “daemon $rserver”. Change this to “start_daemon $rserver”.

  8. Save the file.

  9. Start YaST and under the “Security and Users” section select “User and Group Management”.

  10. Near the upper right corner there is a drop-down “Set Filter” box. Change this to “System users”.

  11. Scroll down and select the user “rstudio-server”. Press the “Edit” button.

  12. Select the “Details” tab,

  13. Add this user to the “lock” group by selecting the “lock” checkbox in the “Additional Groups” box.

  14. Click the “OK” button to save this and then click “OK” on the user screen to save all the changes.

  15. You’ll need to reboot.

  16. You should be able to test it by opening a browser and typing http://127.0.0.1:8787 You’ll get a login prompt and just enter your OpenSUSE account name and password and you should get the RStudio IDE in your browser. You can type 1+1 and if you get 2, I guess it’s working. :slight_smile:

I’m sure you’ll want to read the instructions about configuring the server and such, but the server itself should be installed and working. If you discover a new mathematical theorem, feel free to name it after me! lol!

Hi, duncreg!

I had just given up any hope when I thought I’d check the forums and saw your post! Thank you for taking the time for testing it out and for putting such comprehensive instructions. Had I been a mathematician, I would have surely named a theorem after you! Alas… I am not. I am just curious enough to want to learn how to use R to my advantage for my management PhD studies…

I followed your guide to the letter. One small exception perhaps is that I have R version 2.14.1 already installed from the devel:/languages:/R:/base repository. But anyhow - after I finished and rebooted, I could no longer ssh into that machine - neither from another computer, nor locally. It seemed like ssh had stopped working. On the “server” machine, I opened up a browser and typed in localhost:8787, and the login panel of R Studio Server appeared. It could not start an R session though, and gave an error message.

I then deleted the symlinks and reinstalled openssh package, and that seemed to restore my remote ssh capability, but I could no longer get through the login panel of RStudio server - it would come up, but would fail to authenticate. On a remote machine, I tried accessing the RStudio server but it would not even bring up the login panel.

For now, I have installed RStudio desktop, and connect to it remotely via ssh -X. Not the perfect solution, but close enough. Alas, I must be missing something from your instructions, since you’ve tested it and it worked in VirtualBox.

Could it be that for whatever reason I got the symlinks wrong?.. Or perhaps I need to use R from a different repository?

I’ve got a few ideas. Is the server still installed? If so, you can run “rstudio-server verify-installation” and see what it outputs.

OpenSSH needs the libcrypto library, so I suspect something is going on there. If you’d like, you could do the following:

zypper repos -e (whatever file name you want) to export a list of the machine’s repositories, and

then in YaST’s Install Software tool, select File -> Export and then select a file name.

You could send the two files to rstudio.10.alcalde@spamgourmet.com and I could use them to set up a virtual machine with the same repositories and installed files (these two steps are just exporting a list of repositories and package names, not your data or anything like that) and try it out and see what happens with an identical configuration. I’ve got an old laptop not doing anything at the moment so I can use that as a testbed and try out ssh and RStudio server between the laptop and desktop. I’m sure we’re close; it’s probably just some little thing extra that needs to be done for your exact configuration; I’m fairly sure it’s something with libcrypto.

I’m also wondering if RStudio really needs the old versions of libcrypto and libssl that the rpm wants; it might also be possible to set up a new RPM with the requirements the same as what OpenSUSE has for those libraries and with the changed config file. That could also be something I could try out. I’ve been meaning to learn about creating packages too. :slight_smile:

Hi, duncreg! Thanks for delving into this. Before you spend too much time trying to reproduce my setup, here is the error message I get upon executing rstudio-server verify-installation (as root):

rserver[3086]: ERROR system error 98 (Address already in use); OCCURRED AT: core::Error core::http::initTcpIpAcceptor(core::http::SocketAcceptorService<boost::asio::ip::tcp>&, const std::string&, const std::string&) /root/rstudio/src/cpp/core/include/core/http/TcpIpSocketUtils.hpp:100; LOGGED FROM: int main(int, char* const*) /root/rstudio/src/cpp/server/ServerMain.cpp:346
Starting rstudio-server: 
touch: cannot touch `/var/lock/subsys/rstudio-server': No such file or directory

This is with the symlinks set as you have proposed. Without those symlinks, the verify-installation would complain about missing dependencies. It also spew a message that there is no command start-daemon. Once I restored the symlinks, that message no longer appears.

Does that tell you anything useful?

Well, I just did some testing, and need to say things are somehow working now! Wow! Despite those error messages I quoted in my previous post, I was able to start rstudio-server both from the server hosting machine, and from a remote machine (after allowing port 8787 in the firewall). I have however not rebooted, as I need to be able to shut down that machine remotely, and if reboot it and it losts ssh again, then I won’t be able to shut it down.

Anyhow, tomorrow, when I start the machine, I will try to access rstudio server again. If it works, then your instructions created the perfect setup. If not, then we will worry about it again :slight_smile:

Thanks once again for your wonderful suggestions! Perhaps you need to alert the RStudio developers about how to make installation on an OpenSuse machine possible!

It’s official now - everything works. I don’t know why it failed the first time I tried - perhaps somehow I got the symlinks wrong. SSH works, and I am able to log in remotely. RStudio also works.

Your solution, duncreg, should make RStudio Server a lot more popular on OpenSuse platforms! Thank you so much for being so thorough and for posting these step-by-step instructions.

Hi, just saw your messages. Great! I’ve got a theory about things starting to work… I know during the time I spend figuring out how to install RStudio and when I did it a second time I ran “rstudio-server verify-installation” at least once during the process to check things. Maybe this needs to be done before reboot or it fixes/initializes something?

I’ll see if the RStudio people are interested in putting the instructions I worked out on their web page somewhere. I’d also like to see if I could figure out the Open Build Service well enough to make an OpenSUSE package or RStudio server. My first attempt at using OBS went as well as your first attempt with RStudio Server. :slight_smile:

It’s not all that hard to install from source. I’ve got scripts to do it up on Github if anyone’s interested. See

https://github.com/znmeb/Computational-Journalism-Server/tree/master/RStudio-Server

I’m hoping the RStudio team will make a source RPM. I might make one in February, but it would be for Fedora and might need some porting done.