Will I be able to successfully run this Ubuntu (linux) setup in Virtualbox? - linux

Have 4 DVI output. Seems I hopefully will have driver support on this. Details are sketchy online about supporting 4 outputs, but seems possible.
My question is from the Linux group and Virtualbox pros.... Will the seamless method of VirtualBox allow me to use all 3 of my monitors for multiscreen. I'd like to stick with Ubuntu and run Visual C# and other tools from my VirtualBox. Compiz effects are just too amazing to want Aero Glass.
What do you think, will my system be able to use the multiple monitors with VirtualBox and this graphics card? I've googled for hours and am still searching for answers.
Edit:
I tried virtualbox last night. Pretty slick, though I had an error in installing Visual C#NET. However, it wouldn't let you drag between multiple screens??? Is this something the host must resolve, or does the guest session need to have special settings for multiple monitors? Haven't been able to find anything in google supporting multiple monitors with virtualbox.

You should be able to configure your screens just fine. Don't know the exact details for an ATI setup, but you should be able to use Xinerama to create a single large virtual desktop, and then just run VirtualBox (though honestly, I prefer KVM, which runs on modern CPUs which provide native virtualization support) full-screen on one of those monitors. You would then be able to have three screens dedicated to Ubuntu, and the forth dedicated to Windows.
You might want to look into the non-Xinerama method of multiple displays. Each display is then treated as its own screen (so you'd have :0.0, :0.1, :0.2, and :0.3 for your X displays). You cannot move applications between the screens, but you get four independent desktops. I personally find that more useful than the idea of a single stretched desktop over multiple displays; when I used a laptop as my primary system, that's what I did, and when I get a second monitor for my computer, I'll likely return to that means of doing things. You'll have to investigate the specifics for such a setup with ATI, but the X server supports it, so it's just a matter of looking at your ATI driver's documentation to put the pieces together.

Related

How can I write CUDA in Visual Studio on Windows and deploy it to Linux?

I'm assisting a professor in setting up a lab for a class in parallel programming. The process will be the following:
A student logs into a virtual machine running Windows 7. This machine has no GPUs available. It has version 7.5 of the CUDA toolkit installed along with Visual Studio 2013. Students are supposed to use Visual Studio to write their CUDA programs/projects.
To test/run these projects, students have remote access to a fairly high-end machine. I don't have physical access to it, but from what I can tell using the command line, it has four NVIDIA Tesla M40s. Students have remote access to this machine via SSH. The issue, though, is that this machine is running Linux (Ubuntu 14.04.5). I'm trying to figure out how to deploy what students write in Visual Studio on Windows to the Linux box with the GPUs. I have limited experience in C, C++, and CUDA. I can work my way around a make file, but specific instructions on this topic (if it's part of the solution) would be appreciated.
I have read this article—Creating CUDA Projects for Linux—which details how to get NVIDIA's sample projects running, but I'm not sure if I can adapt this to work in the given situation.
I'm looking for a simple way for students to write assignments in CUDA, but they also need to be able to run what they write. The reason that this professor and I prefer Visual Studio are:
It's something many students in this class are familiar with
It handles project architecture fairly well
It offers students a GUI which can help reduce the learning curve (students can focus on CUDA instead of terminal, gcc, etc.—these things are undeniably incredibly useful, but they're not the focus of the class)
If the test machine were running Windows, then students would be able to simply transfer the contents of the debug or release folder for their solutions in Visual Studio (on the development VM) to the test machine and then run the executable. Since there are two different operating systems in play, I don't imagine it will work like this. I know that writing code on Windows and deploying on Linux won't be quite as easy, but I'm hoping there's a feasible solution.
Reconfiguring the setup and having students develop directly on the test machine or creating a Linux VM for development is doable, but should be avoided if at all possible. Reconfiguration would require involving the systems admin team and would delay the process of getting students writing code.
I have researched this and I've come across these questions, but they don't quite apply to this specific case:
How to write programs in C# .NET, to run them on Linux/Wine/Mono?
How should I develop CUDA on OSX and the deploy test on Linux
The direct answer to the question is that it is not really practical to try to take a VS solution/project and reconstruct it in linux. It may be possible, but I wouldn't put that burden on students trying to learn GPU programming.
An alternative would be to have your students use an X-forwarding SSH client such as Mobaxterm or else a remoting solution like TightVNC from the windows box (VM) to the linux box where the GPUs are. There are some nuanced differences between these two approaches. I believe the X-forwarded SSH client approach will have somewhat lighter network load and does not actually require an X-desktop to be running on the target, whereas TightVNC is an actual remote desktop solution. Therefore the user experience may be somewhat different for these two approaches, however if all the machines in question (windows VMs, linux GPU box(es)) have 100Mb or faster networking between them, and you're only running a few clients at a time, I think it may not matter much.
Either solution will probably work best if you establish individual user accounts on the linux box for each student/client.
And since the students will be sharing the GPU resources, if multiple students are trying to run projects simultaneously, there could be issues, but probably not a problem for introductory level programming work.
Once they have made a connection, the students can then launch nsight to run the linux-based GUI IDE (nsight Eclipse Edition) to build CUDA projects, and run/debug/profile them.

How to simultaneously run multiple window managers (esp. xmonad) for VNC

I'll start with a little background. A small project of mine has been to try to use my Android tablet as an external monitor for my laptop using a VNC client (vnc4server). There are two main options for doing this that I have seen. The simplest is to use xrandr and widen the screen, creating a section just for the tablet. However, this can cause some graphics issues if I understand correctly, although it has the benefit of permitting windows to cross displays. The other option is to run a separate desktop session for the VNC server.
I have chosen to go the route of a second desktop as the session can live and die without significantly affecting my main session and can in theory be tailored specifically to the tablet. A little tool called x2vnc allows me to connect to the VNC server in a similar manner to the more popular Synergy and use it like a n external monitor. I also have the nice little benefit of being able to easily and cleanly switch from landscape to portrait using xrandr.
This brings me to my current issue. So far, I have only been able to reliably use plain x-windows. Although this is entirely functional, I would prefer something more complete. Although xstartup examples have been posted for a variety of window managers, none of these seem to run properly. I suspect all of these are for headless systems. Gnome/Unity are each unforgivably slow and seem to conflict with my existing session. I also feel that these are a little too cluttered for my ten inch tablet. On the other hand, Xmonad simply crashes as soon as I try to open a second window in addition to not updating the graphics properly.
I would like to know anything that will lead me in the direction of a better stable desktop environment. This includes configuration tips and alternate window managers.
I am currently running Ubuntu 12.04 with gnome-xmonad (recently Unity). My xstartup is plain x-window-manager. I have tried any readily available examples for gnome and xmonad that I have been able to find.

Switching to linux [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
I've been using linux at university for quite a while, and it seems much more customisable and better for coding.
So I want to switch to linux from windows 7 at home.
What branch of linux should I use? I'm an emacs user if that gives any insight.
Which desktop enviroment should I use? At uni we use KDE, but it's too graphical, often I just click on stuff instead of using the terminal. I want one where it encourages me to use terminal more.
and the biggest question, how do I install it all? Should I put everything on external hard drive and wipe my computer completley?
I primarily program in Java and python.
I would recommend that you first try using Linux off Live CD/DVD. Linux Mint, Ubuntu, etc.
Just download and burn .iso onto blank media and boot your computer off of it. Just play around, check various desktop environments, see if all your hardware work with the specific Linux distribution. This step is very useful to decide which distribution you actually want to install onto your computer, especially the latter since, while it has been improving, the biggest obstacle you may face in configuring your computer to run on Linux is often hardware incompatibility. Just make sure everything that you need to work actually works.
If you have no issues wiping out Windows, Linux installation is pretty straightforward these days. It even takes less time in general than re-installing Windows. I would browse the web for an installation note for your specific computer model to see if anyone has already successfully done so, so that you can just follow. That saves a lot of time.
I use Debian (Wheezy now) and KDE. It's very easy to install and switch desktop environments after installing Linux though, so that shouldn't be any concern.
I suggest creating a virtual machine using VMWare or Virtual Box. As far as the distribution goes, Linux Mint and Ubuntu are pretty user-friendly for first time installations. And for the desktop environment, I suggest XFCE.
A few Google searches will do you good. I think a virtual environment will be much more easier to manage than partitioning a hard-drive.
Well, the installation step, if you use Windows 7, you may want to make a full backup of your hdd - so if things go wrong you will be safe and able to recover.
I was in somewhat similar situation recently - figuring out which linux distro to use. Previously I had luck with ScientificLinux, but this time it didn't like my laptop hardware for some reason - after wake-up wireless network card was getting stuck and wasnt picking any signal. I didn't want to recompile kernel etc., so I installed Ubuntu, but the Gnome 3 was a show stopper - I had to roll back to Gnome 2, but later I tried and liked a lot XFCE desktop - which I use right now on my workstation and laptop.
Java, Python and emacs probably work well with any linux distribution out of the box, so it is up to you which one to choose after all. Good luck!
Sorry, forgot to mention - all contemporary Linux distributions are able to install a dual boot feature - so you can keep your Windows 7 setup along with Linux (if you have enough of free space), moreover Windows partition will be accessible from Linux which is handy sometimes.

Looking for a super tiny linux distro that's sole purpose is running an AIR application?

I'm looking for a really really small linux distribution or process of making my own that's sole purpose is to get an air application to launch full screen and stay there; Essentially I'm building a home kitchen computer that runs entirely as an AIR app.
I have looked into using windows xp; and windows xp embedded but they pose so many issues I figured I'd try modern linux.
I have also seen TinyCore Linux which looks interestingly small but not sure what issues that poses in regards to running AIR and "hardware" accelerated display. I've also thought about stripping down an Ubuntu installation but I'm sure somebody must have done this already; google is just failing me right now...
I'm also interested in running an "embedded" version of say android and running the air app on some arm-based hardware again; with just the AIR runtimes only - although this is less preferred as it's more complex.
I'm also hooking this up to a touch screen monitor (not yet arrived) so I'll need to hunt down or write some drivers for translating the touch events into something AIR can understand... (this was my main intention for using windows in that all the drivers will just work).
What I'm after
Minified Linux kernel with JUST the drivers for the box I need
X Display with accelerated graphics support (Doesn't have to be X if AIR can run on a frame buffer?)
Running a Full screen AIR application (simple enough)
Ability to write back to the filesystem (enough support for AIR)
SSH Access for remote control
Samba for updating the filesystem (easier to maintain the system)
Touch screen support (3M Ex III I think...)
Audio support
Don't need
Don't need any window manager or any other GUI tools unless required by AIR
Don't need any toolbars or file managers or anything; The AIR app is the "OS"
Don't need any package managers or repos
Don't need multi user or logging in; everything can just run as an unprivileged account
Don't need to
I don't mind hand crafting the filesystem and configs if that makes it easier; I'm mainly looking for a "filesystem" that is as tiny as possible that I can just plop my AIR app into and write some scripts to get it to start when the X server starts
Thanks,
Chris
Try an embedded Linux build system such as Buildroot. It can build an entire system from source, and be very lightweight. The basic system is less than 1 MB in size.
Ended up going with Tiny Core. Very tiny and quick to boot up. You can also write extensions for it and you don't have a persistent drive which allows you to just switch the thing off without worry that it's going to break something -- exactly what you need in a kitchen :-D.
My current plan is to:
Just set up a working version using Ubuntu as this is mostly supported by Adobe
Slowly strip it back and try and get as little things to start as possible on boot
Try building my own distro/package from source and selecting only the packages I need
Compile my own kernel with nearly everything turned off and just leave on the things I need

Advantages of Using Linux as primary developer desktop [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
I want to get some input on some of the advantages of why developers should and need to use Linux as their primary development desktop on a daily basic as opposed to using Windows. This is particulary helpful when your Dev, QA, and Production environments are Linux.
The current analogy that I keep coming back to is. If I build my demo car as a Ford Escort, but my project car is a Ford Mustang, it doesn't make sense at all.
I'm currently at an IT department that allows dual boot with Windows and Linux, but some run Linux while the vast majority use Windows.
Here's several advantages that I've came up with since using Linux as a primary desktop.
Same Exact operating system as Dev, QA, and Production
Same Scripts (.sh) instead of maintaining (.bat and *.sh). Somewhat mitigated by using cygwin, but still a bit different.
Team learns simple commands such as: cd, ls, cat, top
Team learns Advanced commands like: pkill, pgrep, chmod, su, sudo, ssh, scp
Full access to installs typically for Linux, such as RPM, DEB installs just like the target environments.
The list could go on and on, but I want to get some feedback of anything that I may have missed, or even any disadvantages (of course there are some). To me it makes sense to migrate an entire team over to using Linux, and using Virtual Box, running Windows XP VM's to test functional items that 95% of most of the world uses.
This is similar but a little different thread going on here as well.
link text
I have to say getting forced into SSH access to a linux development box for PHP/MySQL development has been one of my greatest and fastest growth experiences as a developer (who formerly worked only in windows XP as a dev environment) as well as bridging some of the knowledge gap between development and sysadmin tasks which is great for developers to understand more about, especially if you ever end up in a one-man army kind of situation.
I was all about windows/eclipse and point and click, and now I am all about VIM and keyboard shortcuts. The color coding/auto tab complete stuff is pretty good these days.
Where I work we use Rackspace Cloud servers for production and development. I imaged the production server (2G ram/CentOS 5.2 stack) for a dev server (so the environment IS EXACTLY THE SAME not close but EXACT) and run it on the smallest instance (256M ram) which is only about $12 month for my dev box. My buddy had a mac he did local dev on for the same codebase and he experienced subtle bugs in the code due to the mac environment, that I do not experience on my cloud dev box (or production).
So what I am getting at is with this type of shift (to the cloud for linux dev with no GUI) portability and quick recovery from hardware failure, and productivity (keyboard shortcuts rule over point/click/drag select) are some other major advantages. Obvs you can learn keyboard shortcuts in Windows too, but when forced to work in only a terminal window, you learn a lot more of them out of necessity. I run Windows 7 on a laptop (essentially as a dumb terminal to my cloud devbox), but I SSH into my devbox with putty and work on code with VIM and manage it with git. If my laptop ever fails or gets stolen, all I really need is ANY computer that has an SSH client (and internet connection) and I can be productive on a temporary loaned computer within 30 minutes until my preferred hardware is fixed/replaced. (all my passwords on the laptop are in a keepass encrypted db which is backed up on dropbox.com as well as external HD, occasional gmail to self). And of course configure putty with nice fonts/font size and full-screen window size.
In contrast getting a windows box from clean install to dev environment tweaked exactly how you want might take a couple full-time days plus a couple hours here and there for a month, and still not replicate the production environment to your needs.
Ok, end biased rant - I guess my point is I didn't know what I was missing as a windows guy, and simple non GUI linux tools for web development have proven to be superior to me for how we work. But also note my laptop is Windows 7, so when work is done or a need to do some IE testing, I'm on a "normal" OS. However, I doubt a lot of people would be willing to make such a change if there is no perceptible gain or immediate need.
I just switched to using Ubuntu from Windows XP, here's what I found:
Pro's of Linux
Linux is less likely to be affected by viruses. I lost some time to viruses when I used XP.
As you said, same environment as Dev/QA/Prod which is nice. It's no longer a change of mindset when I connect to one of those machines
Linux is more stable. I usually rebooted XP every week or two.
You get to use the unix tools (find, pkill, grep, etc.). Cygwin is a workaround but seems quite a bit slower than running unix natively.
Performance seems quite a bit better on Linux. This is probably the biggest win for me, I have a memory-intensive Dev environment.
Cons of Linux
Open Office is a bit of a shock to the system compared to Word/Excel (which I have been using for many years).
I miss Notepad++
I need to run VirtualBox to host my local Sql Server Dev database
I need to run VirtualBox when running internet explorer
More of a pain to copy/paste text between Sql Server Management studio and IE if needed because they run in VirtualBox
Remote Desktop is more of a pain. Microsoft's remote desktop allowed me to not have to log out from work before working at home and vice versa
I have one app that only runs with the Wine emulator and won't work at all for me when remote desktop-ing on linux
I agree with the poster who said it's good to give developers a choice - they will appreciate that instead of having one or the other OS rammed down their throats. An added benefit is that you'll then be able to differentiate the good devs from the bad :) Just kidding.
On my first employment, we had been working on HP UX systems. So I really learned love the power of the console and it's elegance:
Use find to work on loads of files
less for really big log or data files without delay
for loops with substring handling to rename thousands of files in seconds.
and many other nice shell hacks to save you time and nerves...
But not many people seemed to agree in my later employments...
However. I only once had the posibility to use a Fedora Linux box for development several years ago. It was a 64 bit system in the first years of their existance. Maybe this was the problem. I was looking forward to use a proper shell again, but was disapointed as Eclipse did not run stable and had a lot of bugs. This was a pitty and a no go. Since then I never again had the chance to use linux as development OS.
As I start to work in a new employment in some days I really think about to give it an other try. Would do you think, is it still unstable? I nearly can't imagine.
You won't have to use Visual Studio.
Since that doesn't seem to be an issue for you, you might provide more details---what languages are you developing in? If it's Java, then you'll be spending most of your time in Eclipse, Netbeans, etc., so it really won't make much difference. What is your budget for the changeover, or what savings do you hope to get?
From your reasons it seems that you're pretty commited to UNIX already.
Why not give the developers a choice?
git runs faster.
...
Okay, not that much of an advantage...
Linux boxes are easier to containerize with solutions like Docker so that you can more easily share your environment with other devs or QA.
Also, if you need multiple boxes talking to each other for your dev setup, then Linux is a more practical solution. I was working on a Windows machine with a .Net solution which had to talk to services on a different box. I chose to install a couple of VM's using the steps described here (http://mytakeon.it/the-complete-steps-to-having-a-virtual-box-up-and-running-on-your-computer/). The Linux VMs were so light weight, easy to manage and faster in booting up.

Resources