this post was submitted on 15 Apr 2024
172 points (96.7% liked)

Linux

48366 readers
697 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

I really want to switch to Linux, up to this point there were two things keeping me on Windows, gaming and work.

Gaming nowadays is a lot easier than a couple of years ago thanks to Valve and Proton, so that's not a problem anymore; with the other one I don't know if I can make something work enough and that's why I'm asking here.

I work as a fullstack software developer with windows products I don't fear for the frontend part because typescript, angular, react, .... those I know I can run on linux with no problem on VS Code; for backend thought: dot.net, visual studio, sql server, ... I think there is no Visual Studio for Linux and I don't know if I can run & debug .net 8 applications on a linux machine? I can use docker for things like databases. Does anybody else has a similar scenario and things that had to overcame? Tips, problems that I may not see now before making the switch, and solutions to my current problems are welcome

top 50 comments
sorted by: hot top controversial new old
[–] eugenia@lemmy.ml 70 points 7 months ago (1 children)

Instead of trying to run heavy and complex apps on an OS that were never designed for, use Windows for work, and then use gaming and your personal life on Linux. Another thing you can do is switch the kind of programming you do, so it's more linux-related, so overtime, you can only have Linux machines. But for the time being, if you're doing windows programming, use a windows machine for work.

[–] Guenther_Amanita@feddit.de 25 points 7 months ago* (last edited 7 months ago) (4 children)

This sounds like the most reasonable answer here in this thread. I couldn't have said it better.

Preferences don't matter if you get paid for it. If your job demands working with software designed for Windows, then use Windows. If you don't do that, you have to find workarounds that cost time and therefore money, both if you are self employed or have to work for a company.
Either you, or your boss, won't be happy long term.

If you like Linux more, then use it in your free time, or maybe consider switching your orientation for development to that platform.

Same for development for Apple stuff (e.g. iPhone apps). Then you're stuck with MacOS too. Or if you have to use certain CAD or Adobe software, then you're stuck on Windows/ Mac too.

Software availability is great on Linux, and today, you can get most of the stuff working on it, even if it isn't designed for that. But is it worth it that time and effort? For me, it wouldn't.

load more comments (4 replies)
[–] breadsmasher@lemmy.world 45 points 7 months ago* (last edited 7 months ago) (2 children)

.NET is now fully cross platform. you can absolutely run and debug applications on linux as you would in windows.

However Visual Studio IDE is windows only (theres a mac version but isn’t the same).

You can use vscode + .net development pack.

Personally I use Jetbrains rider (for home and work)

SQL Server has a linux version I believe, but its been years since Ive done an install (for development I run sql server in a container)

[–] d3Xt3r@lemmy.nz 13 points 7 months ago* (last edited 7 months ago) (1 children)

.NET is now fully cross platform. you can absolutely run and debug applications on linux as you would in windows.

Correct me if I'm wrong, but isn't this limited to just console apps - as in you can't yet run GUI apps, unless you're using a cross-platform toolkit like Avalonia, or it's a WinForms app running under Mono?

[–] breadsmasher@lemmy.world 9 points 7 months ago* (last edited 7 months ago) (1 children)

To be more specific, yeah I think you are correct. The core of .net (hence the old name net core) is cross platform. Theres a lot of other stuff that isn’t (ie WPF won’t work on linux)

~There are alternatives, such as MAUI~

https://dotnet.microsoft.com/en-us/apps/maui

[–] sylveon@lemmy.blahaj.zone 9 points 7 months ago (1 children)

Note that MAUI doesn't officially support Linux.

But there are third party alternatives like Uno Platform or Avalonia UI that do.

[–] breadsmasher@lemmy.world 7 points 7 months ago

woops! good point thanks!

load more comments (1 replies)
[–] Max_P@lemmy.max-p.me 30 points 7 months ago (4 children)

For the work part in particular, you may find that a virtual machine will get the job done pretty well. With modern CPUs there's basically no overhead, so it's often easier to just run the OS you need in a VM.

You can just run it in the background, run your .NET and SQL server and stuff, possibly VSCode remote into it. PowerShell over SSH. If you need to run a GUI application, you can just RDP into it. FreeRDP has a cool feature where it can RDP a single application so it pops up as any other app on the host. Works great when you just need the database's GUI or whatever.

With virtio drivers and everything, it will be essentially as fast as if native. GUI will be slow because of software rendering, but the point is to use it as a server and only use the GUI as necessary, and for server stuff RDP isn't too bad given it's basically localhost network.

There's also the fun but painful world of VFIO and passing through a real GPU into the VM and feeding back the video to the host with Looking Glass. It's so good you can game on that (anticheat still won't work though, they don't like VMs), so if RDP bothers you that's an option. Although in my experience, Visual Studio is just as slow and buggy natively, so I wouldn't bother and just RDP.

If you add virtiofs to the mix, in theory you can share the code folder and use VSCode on the host and compile on the guest, or even compile on the host and run on the guest. Or send compile commands to Windows over SSH from VSCode. I have my entire Steam library (and Proton containers) on virtiofs and it works perfectly, so I have to imagine a code project should work nicely as well.

Virtual machines are an awesome tool. There's also the benefit of keeping all the work stuff in a big isolated container. If you have multiple projects you can make multiple VMs and not worry about one project needing version X and the other version Y of whatever.

[–] jjlinux@lemmy.ml 10 points 7 months ago (1 children)

And this is why I didn't comment. I knew someone had already suggested the VM way. This is the best way to keep your stuff separate from work related.

[–] space_comrade@hexbear.net 3 points 7 months ago* (last edited 7 months ago) (2 children)

I don't like VMs because I need to allocate memory upfront for it, and considering it's a Windows VM and depending on the dev work you're doing on it you might need to give it 10Gb+.

If it's at all possible for OP I'd recommend getting a separate physical workstation and then just remoting into it with your Linux machine, if you use VSCode the process is pretty much seamless, you use VSCode from your Linux machine normally while all the work is being done on the remote machine.

load more comments (2 replies)
[–] Flaky@iusearchlinux.fyi 3 points 7 months ago

Has Virtiofs matured lately into something that can be used day-to-day? I ask because I think the virtio stuff will be better for Windows virtualisation in the long-term, especially when VMware's future is not certain, but I heard folder-sharing on Windows guests was pretty bad from Lemmy recently, and a few years ago I tried it and yeah, I have to agree.

[–] nexguy@lemmy.world 2 points 7 months ago

Just wanted to add that no one should ever NOT be using a vm as their dev machine.

[–] Enoril@jlai.lu 2 points 7 months ago (1 children)

Exactly what i did. Help also to not mix work and private life by having 2 distinct VM: one with ArchLinux for Gaming/Private apps, one with win10 for work

load more comments (1 replies)
[–] bruce965@lemmy.ml 19 points 7 months ago* (last edited 7 months ago)

Yes, you can develop in .NET on VSCode and the debugger works on Linux too.

There is a Docker version of SQL Server which funnily enough is equivalent to the enterprise version (rather than limited like SQL Express). You can use it for free as long as it's for development purposes only.

There is no SQL Management Studio though.

One option would be to use PostgreSQL instead. Entity Framework makes it almost free to replace the database anyways (unless you are doing some db-specific things).

There are some other minor annoyances or missing features, it might bother you; but depending on how you are used to work, you might not even notice. But, hey! you are on Linux now, you get all the benefits of a UNIX operating system, it will be worth it for sure, right? (Yes, imho)


As for gaming, I only do light gaming so I probably don't count. I use Heroic Launcher and it works wonderfully out of the box 50% of the time, the remaining 50% you can probably make it work as good as on Windows if you are persistent enough.

Oh, and sometimes some games run better on Linux than on Windows, but I would say most of the time they run a bit worse.

[–] om1k@sopuli.xyz 16 points 7 months ago

VSCode or JetBrains Rider are good options for .net development, both available on Linux.

[–] flashgnash@lemm.ee 16 points 7 months ago (1 children)

I am a dotnet dev using Linux as my primary OS. Dotnet core fully works on Linux now, there's a native Linux dotnet cli that works almost identically to the windows one

SQL server I think has been able to run on Linux for a while anyway

You'll have to learn to live without full fat visual studio but honestly you're better without it anyway it just stops you from learning the stuff you really ought to know by doing it all for you

VSCode is a pretty good replacement and actually nicer to use if you know what you're doing, neovim if you want to end up spending all your time configuring it (said as a neovim user)

Gaming is absolutely not an issue unless you play certain competitive games with weird anticheat (valorant for example)

As others have mentioned, docker and VMs exist if you have a reasonably powerful machine so nothing should be completely inaccessible to you anyway, on the windows machine I have to use at work I ironically do most of my dotnet dev on a Linux VM anyway

[–] floofloof@lemmy.ca 8 points 7 months ago (1 children)

There's also JetBrains Rider for a .NET IDE that runs on Linux.

[–] flashgnash@lemm.ee 4 points 7 months ago

True, not free though and I think IDEs like visual studio proper abstract things away that you should probably have some understanding of

[–] domi@lemmy.secnd.me 11 points 7 months ago

I'm also a C# dev and I have been using Linux for years now.

VS Code was pretty much unusable in the beginning when compared to VS. However, nowadays VS Code is very capable at syntax highlighting and debugging.

There is no support for WPF and Forms applications on Linux, since I mostly write web and console applications I don't mind running a Windows VM for those few exceptions. There is also no support for Maui applications but as things are going right now it seems to not be going anywhere anyway.

Since we mostly deploy to Linux servers nowadays anyway it has actually made my job easier since I can run Docker without having to fiddle with it every day like I had to on Windows.

[–] Panda 10 points 7 months ago (1 children)

I use Jetbrains Rider on Linux which runs just fine. It takes some setting up to install .NET but it didn't take me too long. Except for pre-release versions, that might take more trial and error.

Overall I'm pretty satisfied with the switch to Linux and I haven't had any major issues. Not with video games, either. Protondb.com is a good website to see what games do and don't work on Linux and you may need to add launch options to get specific games to work or switch to a specific version of Proton.

It's up to you to decide if it's worth it for you or not. You could try a dual boot setup first.

[–] eluvatar@programming.dev 3 points 7 months ago

Rider gang show up

[–] bjoern_tantau@swg-empire.de 9 points 7 months ago

With the games, make sure that you don't want to play multiplayer games with unsupported anti cheat. They will probably never work on Linux without support from the game developers. See https://areweanticheatyet.com/.

[–] teawrecks@sopuli.xyz 7 points 7 months ago* (last edited 7 months ago)

Even if you can run your .net code on linux, it's better for you to run on the actual platform you'll be deploying to. You could dual boot just for work (that's what I do) or try running in a VM, but I assume your work is hard enough without generating new friction.

[–] poinck@lemm.ee 6 points 7 months ago (1 children)

If you don't play the latest game titles with DRM you should be good to go on Linux: Steam runs great in a flatpak sandbox.

I don't know how compatible mono is with dotnet. Interestingly, some game launchers need it and protontricks can handle many issues. Have look at protondb. Back to work: Someone needs to confirm whether MSSQL server can be run on Linux, but I am almost sure that you won't be able to run the gui of it. But you can connect to it using DBeaver (Java-based) or a VSCode plugin. As for C# development on Linux, I don't know.

I wish I could switch to Linux at work, too, but standardization of work environments seems to be the problem. I would even consider Ubuntu 22.04 LTS if my employer woul allow it. Last time I asked, time was the real reason. Time savings in the long run, currently don't matter. I will ask later and if they still tell me, it's too risky, I will look elsewhere.

Our dev setup doesn't even have the constraints you have for your work. It is all docker-based with Ubuntu Linux containers. It would run faster on Linux even if we could switch to WSL2. And I would argue, that Linux is more standardized than Windows.

I hope you get your stuff running on Linux; market share needs to go up so that all the managers don't fear it. (:

[–] cmnybo@discuss.tchncs.de 3 points 7 months ago

A lot of times the DRM issues can be fixed by using a cracked version. The real problem is the games that force the rootkit based anti cheats that really just make the cheaters switch to hardware based cheats instead of stopping them.

[–] Swarfega@lemm.ee 6 points 7 months ago (1 children)

Get a second drive and install Linux on it. You can then flick between the two on boot. I've done this and now booting into Arch more than Windows. I'll still boot into Windows for reasons but Arch is my main OS now.

[–] possiblylinux127@lemmy.zip 2 points 7 months ago (4 children)

Better to use virtualization for privacy, stability and convenience

load more comments (4 replies)
[–] utopiah@lemmy.ml 6 points 7 months ago

I never thought I'd say this but... in your case, for work at least I would actually stick to Windows! It looks like most of your tools are from Microsoft and that the environment they will normally run on is Windows. It seems most pragmatic to stay there.

For gaming though (as I've argue few times and can be seen from my history), Proton works well, even for AAA games, unsupported (officially) games and VR. ProtonDB helps you to quickly assess if that's the case for your specific games.

Anyway, what I would suggest though is step back, i.e WHY do you want to step away from Windows. If it's technical then "just" dual boot and properly separating fun from work might be sufficient. If it's more moral and ethical, then earning money from tools that are NOT from Microsoft to gradually decouple, remove the dependency on it, seems like the "right" thing to do.

[–] Procapra@hexbear.net 4 points 7 months ago (2 children)

Tips for switching to linux:

  1. Determine if your hardware will play nice with linux. If you have Broadcom or Realtek wifi/bluetooth be aware that linux doesn't always have great drivers for those. Nvidia gpus don't always play nice with wayland.

  2. Certain anti-cheats for games just don't work on linux.

  3. (might not apply to you since you're in IT) Try to avoid using obscure linux distros or bleeding edge distros like Arch. You'll run into issues and not many people will be able to help. Debian, Fedora, and Ubuntu seem to be the popular distros rn for most people.

[–] 1boiledpotato@sh.itjust.works 5 points 7 months ago (1 children)

I don't agree with the 3rd take. I used both Debian and Arch based systems. Both break equally often (quite rarely), but when smth breaks in a Debian based system there's little support or help, while on Arch everyone is willing to help you and you have Arch wiki, which is in a league of its own. Also thanks to AUR, there so much more software available out of the box on Arch

[–] swab148@lemm.ee 1 points 7 months ago

I'm actually switching my mom over to Manjaro today specifically because of the AUR. The reason she hadn't switched before was a very niche embroidery program that we were both convinced would be a Windows exclusive, then two days ago I found out that someone had packaged it earlier this year!

[–] bleepbloopbop@hexbear.net 2 points 7 months ago* (last edited 7 months ago) (1 children)

You'll run into issues and not many people will be able to help. Debian, Fedora, and Ubuntu seem to be the popular distros rn for most people.

Agree with the broader conclusion that a first time linux user should probably avoid gentoo, arch, whatever, but its not because nobody will be able to help you, more just that the expected level of polish is a bit less.

It isn't considered a huge inconvenience to have to use the CLI or edit a config file by arch users, but for ubuntu especially they are more bent on building something that "just works" for most people (with the tradeoff being it's a commercially exploited product, and the innards of GNOME and the like tend to be more of a black box and less tweakable than say, a tiling WM)

But if you do want to dive in and learn how more of the internals work and how to configure things at a lower level, you will find a lot of help with issues, and very detailed documentation for a lot more things in Arch, vs Ubuntu. I find the ubuntu community online to be sort of a middle ground between the detailed technical help I've gotten from Arch communities, and the "here's some magic steps that worked for me, no idea why" type of thing that is prevalent on windows support communities.

Which isn't to say ubuntu people aren't helpful, but the critical mass of users isn't the only thing that matters, it also helps if the users are knowledgeable, and friendly (some arch people fail at this, though I've lucked out and really not had any bad experiences)

[–] Procapra@hexbear.net 2 points 7 months ago

I meant more that, when it comes to newer bleeding edge software, some of the bugs introduced won't be as well recorded and people won't know exactly how to remedy your specific problem. Whereas with debian/ubuntu or fedora, often its as simple as typing whatever problem you're having into a search engine, plugging some junk into the terminal, and it fixing the problem 90% of the time.

But I agree with your comment overall so have my upvote! :)

[–] dan@upvote.au 4 points 7 months ago

don't know if I can run & debug .net 8 applications on a linux machine

The .NET SDK is cross-platform. Try install it then run dotnet run in the same directory as your project file (.csproj).

Most .NET APIs are cross-platform, but there's a few that still only work on Windows, and it's also possible to write code that only works on Windows, like using P/Invoke to call a Win32 API.

[–] Metju@lemmy.world 4 points 7 months ago

Fellow .NET dev here, switched to Linux for side-gigs recently.

In general, the experience is a lot better than Windows / WSL. Some general remarks on the setup (relevant mostly for Debian-based distros, so YMMV):

  • Rider / VSCode suggestion is spot on; go with the former if you have cash to spare and you're fine with snaps, otherwise - DevKit can do DevKit things (with the only problem here being lack of .dcproj support in VSCode; can be ignored with proper integration test setup).
  • Containerization of DBMS: by all means, go for it if you have the resources to spare.
  • Possible gotchas:
    • If you're going to use MS apt feed for .NET runtime / SDK, set up apt preferences to point to their feed for dotnet packages. Otherwise, you're in for a bad time when running updates.
    • Docker: personally, I recommend Rancher Desktop for this purpose, as Docker Desktop on Windows left a bad taste in my mouth. If you're fine with the latter, it's up to your own preferences then.
    • Test containers: if you do use it with anything else than standard, bare-bones Docker setup, you'll need a custom config; stumbled upon that the first time I tried running integration tests.
[–] ososalsosal@aussie.zone 3 points 7 months ago* (last edited 7 months ago)

If you can shell out for it, get jetbrains rider. It's just as good (better?) as visual studio for dotnet including the more obscure bits like xamarin etc

[–] Diffuser5593@aussie.zone 3 points 7 months ago

I ran a dual boot on my work laptop with Windows and Mint until I was fully ready to transition over to Linux. Might be worth doing the same? Recently got rid of the Windows boot and am now fully on Linux for work development. However, I'm not in the web development space so can't comment on that. I use CLion, Intellij, and PyCharm for work.

My home pc is fully Linux running Fedora which I use for gaming, no issues there running Proton through Steam. Have Lutris setup as well for League Of Legends, although that'll be disappearing once Vanguard is integrated.

[–] ms264556@beehaw.org 3 points 7 months ago (3 children)

I don't play games, but I do plenty of dev work including a lot in Visual Studio & SSMS. I always have a few Linux boxes running & try every few months to live on Linux rather than Windows.

Visual Studio can be swapped out for Rider. Rider is quite different feeling than VS, but I guess a lot of devs use another Jetbrains IDE of some kind, in which case it's a fairly easy switch.

SQL Server runs happily on Linux. But SSMS is harder for me to do without. I have Aqua Data Studio & Jetbrains DataGrip, but they don't feel as seamless as SSMS.

In the end though, it's hard to beat Windows + WSL2 now that Windows VSCode & Jetbrains IDEs seamlessly connect to Linux projects. And if you enable nested virtualization and MAC address spoofing then Hyper-V can run anything WSL can't.

Usually I end up moving back to Windows because of font rendering. I far prefer Windows cleartype font rendering on 2160p desktop screens. One day Linux fractional scaling will be perfected or 200+dpi desktop screens will become affordable. Then I might stay on Linux.

load more comments (3 replies)
[–] luthis@lemmy.nz 3 points 7 months ago* (last edited 7 months ago)

Lutris can be pretty handy for many things..

I don't have too much exp with these things, but I would suggest (as an IT support person) narrowing down and isolating problems into specifics, like:

  • I need dot.net for x thing and I tried y thing and it didn't work.

You'll be able to get better answers. I'm pretty interested in the suggestions, my usual solution is 'find something open source that is not as good but works.'

[–] DmMacniel@feddit.de 3 points 7 months ago (1 children)

Afaik the only solution to your .net needs would be mono

[–] theroff@aussie.zone 4 points 7 months ago* (last edited 7 months ago) (1 children)

There's also dotnet (.NET Core) available on most distros which is an open source subset of .NET by Microsoft

See https://fiodar.substack.com/p/differences-between-mono-and-net-core

load more comments (1 replies)
[–] isVeryLoud@lemmy.ca 2 points 7 months ago* (last edited 7 months ago)

You can try JetBrains Rider for .NET, but it's only natural that you won't be able to write Windows applications outside of Windows.

I'm personally impartial to JetBrains for my IDEs on Linux, they work really well and are well supported.

[–] cetvrti_magi@lemmy.world 2 points 7 months ago (1 children)

You can do .net on Linux but Windows is much better for that. I recommend using Windows for work and Linux for everything else.

load more comments (1 replies)
[–] bizdelnick@lemmy.ml 1 points 7 months ago
load more comments
view more: next ›