Coder Social home page Coder Social logo

phanduc / debian-nvidia-xrun Goto Github PK

View Code? Open in Web Editor NEW

This project forked from sudakatux/debian-nvidia-xrun

1.0 1.0 0.0 55 KB

Utility to run separate X with discrete nvidia graphics with full performance

License: GNU General Public License v2.0

Shell 100.00%

debian-nvidia-xrun's Introduction

nvidia-xrun for Debian Tested on Lenovo Yoga

So this is just a fork of the original script, Adapted So that it works for Debian 9. I've only tested this on my machine. Which is a Lenovo YOGA. This Readme describes a step process of how to get this working. and some scripts

My nvidia card is NVIDIA Corporation GP107M [GeForce GTX 1050 Mobile]

Add Debian Stretch backports:

  1. echo "deb http://httpredir.debian.org/debian stretch-backports main contrib non-free" | sudo tee --append /etc/apt/sources.list > /dev/null
  2. sudo apt-get update

Install the Kernel sources for your kernel

apt-get install linux-headers-$(uname -r|sed 's/[^-]*-[^-]*-//')

Or if you are using a backports kernel as i am (needed for my touchpad)

apt-get install -t stretch-backports linux-headers-$(uname -r|sed 's/[^-]*-[^-]*-//')

Install the nvidia-driver

apt-get install -t stretch-backports nvidia-driver

Install bumblebee and Ia32 support

sudo apt-get install bumblebee-nvidia primus

sudo dpkg --add-architecture i386 && sudo apt-get update && sudo apt-get install -t stretch-backports bumblebee-nvidia primus primus-libs:i386 libgl1-nvidia-glx:i386

Add your user to bumblebee

sudo gpasswd -a $USER bumblebee

Run just-copy Script

run the ./just-copy.sh script. Or follow the steps in the script

Reboot and Sanity Checking

If everything went well reboot. After the computer boots you should be able to use X with your normal Intel driver. but you need to check if bumblebee works as expected. On a console type optirun glxgears -info

That should run glxgears using your nvidia card. With a poor performance, but in a way confirms you are on the right track lsmod | grep nvidia should show the nvidia kernel module is there as well

Testing installation

CTRL+SHIFT+F2 Will take you to another tty. We want to disable display manager (Asuming you are using sddm) So stop your display manager systemctl stop sddm

if using kde you want the script to start kde when runned so echo startkde > ~/.nvidia-xinitrc That will start kde when running the nvidia script. Anyway lets test it : Typing nvidia-xrun Should run X with your drivers enabled.

Finalizing Installation

If everything works run glxgears -info You should see much much better performance than before. exit X by logging out and run systemctl disable sddm So that sddm does not start at boottime.

Summary

To run with the intel card run startx To run with the nvidia card run nvidia-xrun

Hope this helps someone. If you run into any issues look at the original project. https://github.com/Witko/nvidia-xrun

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.