cp /etc/X11/xorg.conf /etc/X11/xorg.conf.intel
mv /etc/X11/xorg.conf /etc/X11/xorg.conf.nvidia
cp /etc/X11/xorg.conf.old /etc/X11/xorg.conf
urpmi git
git clone git://github.com/Bumblebee-Project/Bumblebee.git
#install_step determinedistro "" "precheck build install postconfig"
#install_step "$DISTRO/setvars" "" "precheck build install postconfig"
#install_step "$DISTRO/checkdependencies" "Checking dependencies" precheck
#install_step "$DISTRO/configure" "" postconfig
cd Bumblebee;./install
usermod -a -G bumblebee YOURUSERNAME
echo "# My args" >> /etc/bumblebee/bumblebee.conf
echo "LD_LIBRARY_PATH=\"/usr/lib64/nvidia-current\"" >> /etc/bumblebee/bumblebee.conf
echo "X_DAEMON=\"/etc/X11/X\"" >> /etc/bumblebee/bumblebee.conf
echo "X_LD_LIBRARY_PATH=\"/usr/lib64/xorg\"" >> /etc/bumblebee/bumblebee.conf
lspci -d 10de: -n | grep '030[02]:' | cut -d' ' -f1
Section "ServerLayout"
Identifier "Layout0"
Option "AutoAddDevices" "false"
EndSection
Section "Device"
Identifier "Device1"
Driver "nvidia"
VendorName "NVIDIA Corporation"
BusID "01:00:0"
Option "NoLogo" "true"
Option "UseEDID" "false"
Option "ConnectedMonitor" "DFP"
Option "AddARGBGLXVisuals"
EndSection
bumblebee -d
optirun kwrite
/etc/init.d/bumblebee start
urpmi git
git clone https://github.com/mkottman/acpi_call.git
cd acpi_call
make
insmod acpi_call.ko
chmod +x test_off.sh
./test_off.sh
Trying \_SB.PCI0.P0P1.VGA._OFF: failed
Trying \_SB.PCI0.P0P2.VGA._OFF: failed
Trying \_SB_.PCI0.OVGA.ATPX: failed
Trying \_SB_.PCI0.OVGA.XTPX: failed
Trying \_SB.PCI0.P0P3.PEGP._OFF: failed
Trying \_SB.PCI0.P0P2.PEGP._OFF: failed
Trying \_SB.PCI0.P0P1.PEGP._OFF: failed
Trying \_SB.PCI0.MXR0.MXM0._OFF: failed
Trying \_SB.PCI0.PEG1.GFX0._OFF: failed
Trying \_SB.PCI0.PEG0.GFX0.DOF: failed
Trying \_SB.PCI0.PEG1.GFX0.DOF: failed
Trying \_SB.PCI0.PEG0.PEGP._OFF: failed
Trying \_SB.PCI0.XVR0.Z01I.DGOF: failed
Trying \_SB.PCI0.PEGR.GFX0._OFF: works!
echo '\_SB.PCI0.PEGR.GFX0._OFF' > /proc/acpi/call
echo '\_SB.PCI0.PEGR.GFX0._ON' > /proc/acpi/call
acpi
acpi
echo '\_SB.PCI0.PEGR.GFX0._OFF' > /proc/acpi/call
sleep 3; acpi
echo '\_SB.PCI0.PEGR.GFX0._ON' > /proc/acpi/call
sleep 3;acpi
#!/bin/bash
USEAGE="useage: ${0##*/} [stop,start]
help: Turns off/on custom power saving
requrs: /etc/acpi/call/acpi_call.ko
Note: Root users only
"
# Check user is root
if [ "$(whoami)" != "root" ]
then
echo -e "${USEAGE}" > /dev/stderr
exit 0
fi
# Check acpi_call module is loaded
if ! lsmod | grep -q acpi_call
then
# Check module exists
if [ ! -e "/etc/acpi/call/acpi_call.ko" ]
then
echo -e "${USEAGE}" > /dev/stderr
exit 0
else
# Install acpi_call module
insmod /etc/acpi/call/acpi_call.ko
fi
fi
# Show battery useage before
echo "Before switch `acpi`"
if echo "${1}" | grep -qEi "start"
then
##############################################################
# HERE you can put whatever code you want to run to save power
##############################################################
/etc/init.d/wine stop > /dev/null 2>&1
/etc/init.d/bumblebee stop > /dev/null 2>&1
echo '\_SB.PCI0.PEGR.GFX0._OFF' > /proc/acpi/call
elif echo "${1}" | grep -qEi "stop"
then
##############################################################
# HERE you can put whatever code you want to run for full power
##############################################################
/etc/init.d/wine start > /dev/null 2>&1
/etc/init.d/bumblebee start > /dev/null 2>&1
echo '\_SB.PCI0.PEGR.GFX0._ON' > /proc/acpi/call
else
echo -e "${USEAGE}"
exit 1
fi
# Wait a few seconds for power usage to update
sleep 3
# Show battery useage before
echo "After switch `acpi`"
cd ..
mv acpi_call/ /etc/acpi/call
cp powersave_custom /usr/sbin/powersave_custom
chmod +x /usr/sbin/powersave_custom
powersave_custom start
powersave_custom stop
Owdy wrote:Please do this
Regards,
ASUS N73SV
isadora wrote:Owdy wrote:Please do this
Regards,
ASUS N73SV
Please do what????
urpmi ./*.rpm
z wrote:I did notice there is now a bumblebeed package which is bumblebee written in C and is supposed to include power management also. There is also bbswitch which can be used to disable the graphics card when not in use, although I haven't tried to install it yet. Does anyone know if either of these will work with Mageia?
Return to Packaging and translating for Mageia
Users browsing this forum: No registered users and 1 guest