Tag Info

New answers tagged

0

A little late, but it is possible to do this - especially with lenovos. See: http://askubuntu.com/questions/34452/how-can-i-limit-battery-charging-to-80-capacity From Ubuntu but works for all lenovos, just need the tp_smpai kernel module. Other brands have similar things.


0

A process is run with a uid ang a gid. Both have permissions assigned to them. You could call chroot with a userspec of a user and group, where actually the user is not in that group. The process would then executed with the users uid and the given groups gid. See an example. I have a user called user, and he is in the group student: root@host:~$ id user ...


0

Using the --userspec option on chroot specifies the user and a single group to use when running the chroot. To define supplementary groups you need to use the --groups option as well. By default processes inherit the primary and supplementary groups of the user running them, but by using --userspec you're telling chmod to override that using the single ...


0

The kernel checks the permissions on the file and the path components leading up to the file against the permissions of the process and if they don't match indicates to process that the target cannot be read (or otherwise accessed) The kernel itself, has no restrictions whatever to getting to the file or reading its data, it actively prohibits processes ...


0

This is because you are using the -a option when you do the copy with rsync and you do not use the -a option with cp. This results in the timestamps on the cp copied files not being preserved. PS giving rsync additional -v options results in additional output. Although I am using rsync version 3.1.0 protocol version 31, which has a slightly different ...


0

The home directory of the user should be relative to the chroot path. If you want to use /var/jail/home/user as the home directory, you will have to set the user's home to /home/user.


0

You need to add a newline at the end of the printf statement, like so: printf "START %10s %10s %10s %10s %10s %10s %10s %10s %10s %10s %10s %5s\n" $f1 $f2 $f3 $f4 $f5 $f6 $f7 $f8 $f9 $f10 $f11 $f12; # ifet the student id (note the \n)


0

That is probably because, you give only 5 positions for 4th field, but it may have six characters like HARRY1 in your example: printf "%10s %10s %10s %5s <...> ^^^ However, there is nice prettifier in GNU/Linux column which automatically selects column width depending on incoming data: $ cat test.csv Harry,2 Ed,3 Mary,4 ...


0

just for fun #! /bin/bash ls /exports/files/*.300 | while read FILE do if mv $FILE /exports/files/arch then echo "$FILE moved" fi done | mailx -s files moved support@abc.com will give you a single mail with all moved file, and skipping the error. with just 3 level of pipes.


0

You shouldn't parse the output ofls, do this instead: #!/usr/bin/env bash shopt -s nullglob for FILE in /exports/files/*.300; do mv $FILE /exports/files/arch echo "$FILE moved" | mailx -s $FILE moved support@abc.com done More info: http://mywiki.wooledge.org/ParsingLs


0

I just learned, with my GA-990FXA-UD7, that for both the USB 2.0 and USB 3.0 controllers and the onboard Ethernet controller to function properly in Linux (I'm using Mint 17.1) it required the following settings in the BIOS: xHCI handoff - Enabled EHCI handoff - Enabled IOMMU controller - Enabled Don't forget to disable UEFI and change all boot options to ...


5

The file in /proc/<pid>/io represent what you need. It's a bit scripting work to get an output similar to iotop. See the linux kernel documentation to the /proc/<pid>/io file values: rchar I/O counter: chars read The number of bytes which this task has caused to be read from storage. This is simply the sum of bytes which this process ...


0

Usually such problems reflect the unavailability of a proper driver. Try opening driver-manager and see if some additional drivers need to be installed. If the above doesn't work, then search for some wireless drivers in synaptic with keywords like wireless, dell etc.


1

You can use Audacity for that. In Audacity, you can select what you wish to use as input. So your input would be visible here and you can select that. Moreover, I think it would be detected as Microphone only, nothing different. In that case, any other software might also do.


0

You can create a user, set its home directory to /var/www/ and add him to the www-data group. If you want the files he will create belongs to the www-data group, you'll have to add the "s" bit to the www directory's mod. # useradd -m /var/www -g www-data # chmod g+s /var/www Or did I missunderstand the question? Maybe you want that this user can't read ...


0

Try connect to wifi manually by wpa_supplicant and dhclient. You should run the follow commands: wpa_passphrase ssid password > /etc/wpa_supplicant.conf wpa_supplicant -Dwext -iwlan0 -c /etc/wpa_supplicant.conf dhclient wlan0 ssid=your wifi name After exec wpa_supplicant wait it to connect, and move it to bg ( ctrl+z; bg ) or use another terminal to ...


1

What dd reads when you run dd if=/dev/cdrom of=foo2.iso is not a file (there is no such thing on a physical CD), but a number of 4KB sectors. If the length of the image file you wrote is not an exact multiple of 4KB = 4096, there will be some padding at the end. You can safely ignore it.


0

You can find most of what you're looking for in /var/log/messages , which is where Linux usually puts logs. I usually run the following three searches with root privilege to get a good picture grep -ir ssh /var/log/* grep -ir breakin /var/log/* grep -ir security /var/log/*


1

Please, give more information on what SSH server you use (OpenSSH, dropbear, etc.). I'm using OpenSSH-6.6. It's configuration file is normally found in "/etc/ssh/sshd_config", although you can specify your own configuration file to the server as an argument to the "-f" option (for example, "sshd -f /my/config/file"). The config file has two options which ...


0

Since the kernel line transparent_hugepage=never only disables half of what I need (both, for annoying mongodb failing/logs), that I didn't persist through systemd startup script but now have: echo never | sudo tee /sys/kernel/mm/transparent_hugepage/enabled. That works in either systemctl boot script (when properly configured one in /etc/systemd/system) or ...


0

can u explain what u mean by a USB stick with FreeBSD on it. Do u mean a freebsd installer or Do u mean a Live FreeBSD version ? If u want a FreeBSD install download a *memstick.img version from: ftp://ftp.freebsd.org/pub/FreeBSD/releases/amd64/amd64/ISO-IMAGES/10.1/ If u want a Live FreeBSD version download a img from: ...


2

Some thing like this should do the trick. If you need to remote in to the server use ssh certificates and executes this script using ssh. #! /bin/bash for FILE in `ls /exports/files/*.300` do mv $FILE /exports/files/arch echo "$FILE moved" | mailx -s $FILE moved support@abc.com done


0

In Ubuntu, I use these commands: ssh -X user@host gnome-session or ssh -Y user@host gnome-session


-2

what you could do is cp the /etc/resolv.conf to /etc/resolv.conf-BKUP then create a cron job to cp -r /etc/resolv.conf-BKUP /etc/resolv.conf like every couple of minutes till you figure it out. within the BKUP file have the correct name servers.


0

I think you could be another surprise victim of the altered ministrations of resolvconf package. Consider editing: /etc/resolvconf/resolv.conf.d/head Ignore the warnings you'll see there, as they are for transferring to other files. Edit it like so, (replacing the "111" and "222"s with sensible nameservers IPs etc): # Dynamic resolv.conf(5) file for ...


0

Hm, I really thought what you have would work. Since you are using dhcp, you could edit the /etc/dhcp/dhclient.conf, find the section for your ethernet device and put in the following: supersede domain-name-servers 127.0.0.1, 8.8.8.8, 8.8.4.4; And the answer to your topic question: dhclient is modifying the file.


3

That is correct, you don't need to keep the extracted source code. If you want to be sure of it before deleting the folders, you can rename them and check that ImageMagick and PDFtk still work... It may be useful to keep the original archives you downloaded along with a note of the commands you used to configure the builds. If you ever want to uninstall the ...


2

This is how I would do this: find /var/backup/ -type f -maxdetph 1 $(printf "! -name %s " ${keep[*]}) \ -exec rm {} \; Note that this will not work if your file names have spaces in them.


1

Just connecting the pins will not generate an interrupt. According to the document you referenced you need to write some data to pin 9 which has a short to pin 10 to generate the interrupt. Quote from your referenced document: Pin 9 is the most significant bit of the parallel data byte. If you write binary data to /dev/short0, you generate several ...


0

Why do people find it so hard to read kernel code? :P. http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/drivers/char/ppdev.c Seriously, it's common for devices to only be activated when they're needed - when userspace opens them. Example: If you look at ppdev.c, you'll see it presents an API where the parport is "claimed" (though not ...


6

The linux swapping algorithm works with the concept of "last recently used pages". Each page in virtual memory has an age associated with it. If the page is being frequently accessed then that page is supposed to be quite young in age while if a page is not being accessed, then that page becomes older. The older the pages get, the more likely they may get ...


1

How about using grep -vE with the following expression: $ echo "$(IFS=\| && echo "${keep[*]}")" ...


-1

Try remove it then re-install: apt-get install python-capstone


2

The disk label type is the type of Master Boot Record. See http://en.wikipedia.org/wiki/Master_boot_record. The disk identifier is a randomly generated number stuck onto the MBR. In terms of tools for looking at disks, fdisk is on it way to being deprecated if it isn't already so. parted is the replacement for fdisk and gparted can be used to provide a ...


-3

Ok, I know I'm a Windows user, not a linux user, but I had a similar issue a while ago when trying to copy files to a 16Gig data stick, to transfer to and from an old laptop. As it turned out, most of the file system formats for removable devices (ext2, fat32 etc), don't support copying files if the file is greater than 3.2Gigs in size, because of some ...


0

Do you have the relevant repo file in /etc/yum.repos.d/? It is not by default on my CentOS7 system. They've made it easy for you to install this first: Go to http://dev.mysql.com/downloads/repo/yum/ and download the file and install it "manually" with rpm. Then your yum command should work.


-1

rsync can use directly ssh,using -e rsync -avP -e /home/share/ remote:/home/share otherwise a tunnel works fine,another solution can be stunell


2

You can open file with F3. Hex view - F4. Start edit - F2.


2

F4 toggles hex mode in the Midnight Commander viewer (accessed using F3), not in the editor. Once in hex mode in the viewer, F2 allows you to make changes to the file being viewed. As you discovered, F4 in the editor starts a search.


2

I often use SSH port tunneling to create an encrypted channel. Since you're using an rsync:// URL I assume you have the rsync daemon running on TCP port 873 on the remote server. We can forward this port as follows: ssh -N -L 873:localhost:873 rsyncssh@server The -N option prevents the execution of a remote command, which would in your case disconnect the ...


1

Ostinato aims to be "Wireshark in Reverse" and become complementary to Wireshark. Ostinato is an open-source, cross-platform network packet crafter/traffic generator and analyzer with a friendly GUI. Craft and send packets of several streams with different protocols at different rates.


9

Your 8GB stick has approximately 7.5 GiB and even with some file system overhead should be able to store the 5.4GiB file. You use tune2fs to check the file sytem status and properties: tune2fs -l /dev/<device> By default 5% of the space is reserved for the root user. Your output lists 97894 blocks, which corresponds to approximately 385MiB and ...


1

Answering the X part of this XY problem, I would recommend you investigate the reason your binary file transfers don't transfer properly. If it turns out the reason is because you don't have an 8-bit clean datapath you could then use existing tools that were created to handle this situation, such as base64 or even uuencode. Old but still very effective. ...


1

od -An -vtx1 Check.tar > Check.txt You need -v or od will condense sequences of identical bytes. For the reverse: LC_ALL=C tr -cd 0-9a-fA-F < Check.txt | xxd -r -p > Check.tar Or: perl -ape '$_=pack "(H2)*", @F' Check.txt > Check.tar If your purpose is to transfer files over a channel that only supports ASCII text, then there are ...


0

why not try guake? It's always running in background,and when you want to use it,press the hot key it will show up! For more detail click here


0

All I can say is reinstall your ubuntu :) .You can setup your nvidia drivers using bumblebee. It has LibreOffice, it almost provides all the features which Windows MS Office provides and it supports different languages too by installing the language packs. And you said you need to stick to Linux,then remove your Windows OS ;-)


0

some_command | cat - /dev/tty ...will work with anything, pretty much. If the launcher you use doesn't properly handle pipelines in a command, you might want... sh -c 'some_command | cat - /dev/tty' You can send an interrupt with CTRL+C to kill cat and end the session, or else just close the terminal window when ready.


0

After I tried many options of aptitude and the ways friends suggested in their posts, I came across a incredible option of aptitude: -f Try hard to fix the dependencies of broken packages, even if it means ignoring the actions requested on the command line. This corresponds to the configuration item Aptitude::CmdLine::Fix-Broken. Using ...


2

No, the OOM-killer is not involved at all. There is no magic. tmpfs just behaves like any other file-system: What sets the size of tmpfs? What happens when its full?


1

xterm -hold from $(man xterm): -hold Turn on the hold resource, i.e., xterm will not immediately destroy its window when the shell command completes. It will wait until you use the window manager to destroy/kill the window, or if you use the menu entries that send a signal, e.g., HUP or KILL.



Top 50 recent answers are included