[131001640010] |How do I connect a serial terminal to a KVM instance? [131001640020] |Perhaps I'm misunderstanding what KVM is capable of, but the ability to add/remove hardware on the VM seems to imply I can add a serial port that then acts as a terminal. [131001640030] |So, my questions are: [131001640040] |
  • Which settings are best for the guest FreeBSD distribution? [131001640050] |(There are many!)
  • [131001640060] |
  • How do I access said terminal from my Linux host?
  • [131001650010] |Well, you have to emulate a serial port within the emulator of course and have that be accessible on the host. [131001650020] |The guest OS should put something on its 'hardware serial port' like a login prompt via e.g., getty_ps. [131001650030] |Now I personally haven't had to use it this way. [131001650040] |Mostly the emulated serial port on the guest OS is used for debugging information (Haiku still uses that by default) and then it is captured by the emulator (like VMware) as a simple text-file to have the debug information available.. [131001650050] |I'll try here to get something running on the emulated serial console within qemu. [131001660010] |I can now answer my own question based on Stefan's comment and the two linked articles: [131001660020] |
  • http://ubuntu.stackexchange.com/questions/1733/what-reason-could-prevent-console-output-from-virsh-c-qemu-system-console-gu
  • [131001660030] |
  • http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=507650#29
  • [131001660040] |Here is the solution: [131001660050] |
  • You need not edit anything to do with the host configuration provided it has the default serial device pointing to pty in there.
  • [131001660060] |
  • Ensure the boot parameter for your kernel has this appended: serial=tty0 console=ttyS0,115200n8. [131001660070] |Usually achieved by editing /boot/grub/menu.lst
  • [131001660080] |
  • Configure /etc/inittab and append the line T0:S12345:respawn:/sbin/getty -hL ttyS0 115200 vt100 to launch a getty and give you the login prompt.
  • [131001660090] |I can confirm this works for me using a fedora system (albeit I did have to set enforcing=0 as an additional parameter because the system in question is fedora rawhide running SELinux MLS). [131001660100] |I think from there I can probably work out how to do the same for freebsd. [131001660110] |Thanks Stefan! [131001670010] |ZFS under linux, does it work? [131001670020] |Could I get ZFS to work properly in Linux? [131001670030] |Are there any caveats / limitations? [131001680010] |I don't know how well they work, but there are two ports of ZFS available for Linux - a FUSE implementation and a in-kernel filesystem implementation. [131001690010] |ZFS is not in the official Linux kernel, and never will be unless Oracle relicenses the code under something compatible with the GPL. [131001690020] |Additionally, NetApp claims they own patents on some technology used in ZFS. [131001690030] |NetApp settled their lawsuit with Sun after the Oracle buyout, but that settlement doesn't protect any other Linux distributor. [131001690040] |(Red Hat, Ubuntu...) [131001690050] |Today, your best options are: [131001690060] |
  • Switch to btrfs, which has similar features to ZFS but doesn't have the GPL license conflict and has been in the mainline kernel for testing since 2.6.29 (released in January 2009)
  • [131001690070] |
  • Use a different OS for your file server (FreeBSD 8, say) and use NFS to connect it to your Linux boxes
  • [131001690080] |
  • Use ZFS on FUSE, a userspace implementation, which works neatly around the kernel licensing issue at the expense of a significant amount of performance
  • [131001690090] |
  • If you are able to integrate a kernel patch on-site, you can use the Behlendorf port of ZFS to Linux. [131001690100] |The license conflict means you cannot sell or give the patched server away to someone outside your organization, as that would constitute distributing non-GPL-compatible code (ZFS) linked to GPL code (the Linux kernel).
  • [131001690110] |Incidentally, btrfs is also backed by Oracle, but was started years before the Sun acquisition. [131001690120] |I don't believe the two will ever merge, or one be deprecated in favor of the other due to the license conflict and patent issue. [131001690130] |ZFS is too popular to go away, but there will continue to be demand for a ZFS alternative. [131001700010] |You can with the FUSE version of ZFS. [131001700020] |The limitation is that it runs as a userspace process. [131001710010] |I have set up ZFS Fuse on debian/lenny for my home NAS. [131001710020] |I didn't encounter any problems or limitations. [131001710030] |Search for ZFS on my blog for some more related posts. [131001710040] |I did try BTRFS first, but found that it simply wasn't ready yet. [131001710050] |This was in february 2010. [131001720010] |ZFS Fuse indeed works. [131001720020] |CAVEAT: Make sure that the 'other' operating systems you'll use the drive for supports the same version the ZFS Fuse - BSD usually runs a couple of versions later than the Linux ones. [131001730010] |Several answers here mention the Behlendorf ZFS port. [131001730020] |Keep in mind that the Behlendorf ZFS port is currently targeted towards Lustre users with extremely large filesystems. [131001730030] |This is what Lawrence Livermore National Labs, the US Department of Energy and other research facilities need, because they run very filesystems (100TB - multi-Petabyte systems in the near future). [131001730040] |Lustre runs on Linux, and is running into problems when used for filesystems above certain sizes. [131001730050] |Some people hope to solve this problem using ZFS, which is where zfsonlinux.org comes into play. [131001730060] |In order for ZFS to be useful for the rest of us, the ZPL (ZFS POSIX Layer) must be ported to Linux, so that administrators can interact with the filesystem. zfsonlinux.org has a development version of the ZPL, and KQ Infotech provides another implementation of the ZPL, which is a fork of the zfsonlinux.org code. [131001730070] |Behlendorf wants help to improve the ZPL and to merge in any changes from KQ Infotech into the zfsonlinux.org repository. [131001730080] |If you can do this, the community will benefit greatly, and you will be a rockstar. [131001740010] |How can I set up smart card SSH authentication? [131001740020] |I would like to be able to SSH to my machine using a Gemalto .NET Smart Card as the authentication method. [131001740030] |How could this be done on a Fedora 13 (or generic Red Hat style) machine? [131001740040] |These are the rough steps I think are needed: [131001740050] |
  • Provision certificate for the smart card (and possibly a CA to issue it?)
  • [131001740060] |
  • Get the certificate onto the smart card
  • [131001740070] |
  • Configure SSH server to allow smart card authentication and configure it to use a particular certificate/CA
  • [131001740080] |
  • An SSH client that has smart card support (extra points for a free Windows based one)
  • [131001750010] |I'd recommend kerberos. [131001750020] |MIT produces a krb5 client &server. [131001750030] |vwduder, could you recommend a smart card reader and a source of FIPS-201 compliant cards? [131001750040] |http://csrc.nist.gov/publications/fips/fips201-1/FIPS-201-1-chng1.pdf [131001750050] |I have a copy on my own server, but I am not popular enough on this stacktrace at this moment to share it with you. [131001750060] |The above is only slightly less reliable than our own servers, so you will probably be able to get it from them ;) [131001750070] |[edit] I'm now popular enough! [131001750080] |http://www.colliertech.org/state/FIPS-201-1-chng1.pdf [131001760010] |When using RSA keys, 1) and 2) are trivial, because as we'll see in 3) the actual certificate is irrelevant in this context. [131001760020] |Just head to cacert.org or generate a self-signed certificate and you are all set. [131001760030] |For 3) you'll need to extract your public key and install it in $HOME/.ssh/authorized_keys. [131001760040] |Pay attention to file ownership and permissions! [131001760050] |(700 for .ssh, 600 for authorized_keys). [131001760060] |Host-wide public key authentication is discouraged but left as an exercise for inquisitive minds. [131001760070] |As for 4) you should look into PuTTY SC ( http://www.joebar.ch/puttysc/ ) or -preferably- PuTTY-CAC ( http://www.risacher.org/putty-cac/ ) which improves upon PuTTY SC with a better public key extraction algorithm and also includes the Kerberos-GSSAPI support from the development branch of PuTTY. [131001770010] |Gemalto drivers are now open source I believe. [131001770020] |They have the source code on their website. [131001770030] |You will need to configure the pam module (I'm not sure how to do this, but the code is certainly there). [131001770040] |I imagine the pam configuration would require a mapping of a certificate principle to a local user id. [131001770050] |GDM I believe supports smart cards now, but I'm not sure how it detects it. [131001770060] |I'll try to look this up later (easiest way is probably to just peek at the gdm source code). [131001770070] |Of course this all requires pcscd and libpcsclite to be installed. [131001770080] |You will also need to copy the libgtop11dotnet.so to /usr/lib. [131001780010] |Convince grep to output all lines, not just those with matches [131001780020] |Say I have the following file: [131001780030] |By default, grep returns each line that contains the search term [131001780040] |Passing grep --color will make it hilight the portion of the line that matches the search expression, but it still only returns lines that contain the expression. [131001780050] |Is there a way to get grep to output every line in the source file, but highlight the matches? [131001780060] |My current terrible hack to accomplish this (at least on files that don't have 10000+ consecutive lines with no matches) is: [131001780070] |If grep can't accomplish this, is there another command-line tool that offers the same functionality? [131001780080] |I've fiddled with ack, but it doesn't seem to have an option for it either [131001790010] |What we're doing here is matching against the $ pattern and the test pattern, obviously $ doesn't have anything to colourize so only the test pattern gets color. [131001790020] |The -E just turns on extended regex matching. [131001800010] |You can try: [131001800020] |Not very portable however, and even if Perl is installed, you may need to download another module. [131001800030] |In addition it will color the entire line, not just the search word. [131001820010] |Any alternative of "man -a" on UNIX? [131001820020] |man -a opens all the man pages one by one which contain xyz. [131001820030] |On my unix servers man -a doesn't work. [131001820040] |Is there any alternative for this on unix? [131001820050] |EDIT: [131001820060] |I am on HP-UX. [131001820070] |Following message : [131001830010] |Is apropos available on the system? [131001830020] |It can be used to search for man pages. [131001830030] |With a quick one-liner, it can come close to the man -a behaviour [131001840010] |There are always emcas-based info pages: [131001850010] |Does man -k work? [131001850020] |If so, then: [131001850030] |might do what you want [131001860010] |linux x.org alternative [131001860020] |We have so many options for window managers, shells, desktop environments, distros, and kernel architectures under Linux, but why after (maybe) 20 years do we only have X.org server (including its predecessor) as the bottom layer of GUI? [131001860030] |I know about XFree86, and Y, but most of them are stuck. [131001860040] |Is it so hard to create a new (i.e modern) one? [131001860050] |Or is there any other reason we are stuck on X.org? [131001870010] |Well, there's SVGALib or fbdev, you could build a window manager on top of one of those, if you'd like. [131001870020] |I think the existing desktop environments (Gnome/KDE) are built on top of the X.Org programming interfaces, so you'd have quite a bit of work to do to make them work on a different substrate. [131001870030] |I've heard that Android uses it's own frame buffer system and doesn't rely on X. Unlike POSIX, there isn't really a portable API for the underlying graphics system, so we all use X by default. [131001880010] |There are several other implementations of X11, but none of them have all the features &driver support that X.org has. [131001880020] |There are also some framebuffer-based solutions like DirectFB and whatever Android uses. [131001880030] |And recently work has been ongoing on Project Wayland, which maybe one day might (partially) replace X11. [131001890010] |Despite the fact that X.org is 20+ years old, what is it exactly that you need from a windows server that it doesn't provide? [131001890020] |You have OpenGL support, anti-aliased fonts, double buffering, spiffy translucent composite windows, hardware-accelerated video playback. [131001890030] |You can even play some DirectX games on it with wine if you're into that. [131001890040] |What makes an X11 server 'modern' in your opinion? [131001890050] |Writing an X11 server is hard. [131001890060] |Developing it and adding features and hacking on top of it for 20 years to keep it relevant is even harder. [131001890070] |The barrier of entry for X server programming is high, and I think there are not THAT many people hacking on it. [131001890080] |In fact, the crucial point of X.org is the ongoing effort to refactor and modularize the existing code mess into a more manageable infrastructure that will allow for easier development and implementation of new features. [131001890090] |While the 'let's rewrite it' thing might look interesting, I think there's not really a point to it. [131001900010] |Well there's Wayland but that's not ready yet. [131001910010] |As others have said, Wayland is the main X.org alternative that is currently being developed. [131001910020] |Right now, it's nowhere near being usable for normal tasks. [131001910030] |However, there have been several exciting new developments. [131001910040] |Earlier today, Kristian Høgsberg (Wayland's author) committed the code changes to Mesa that are necessary to run Wayland to the master Mesa branch (they were previously in his personal repository). [131001910050] |This should make it easier to use Wayland, because, eventually, you should be able to use your distro's Mesa package rather than compiling it yourself. [131001910060] |(Mesa is by far the largest package that needs to be built to run Wayland.) [131001910070] |Recently, Kristian posted a screenshot of his initial support for using Gtk+ in Wayland: [131001910080] |There is also the start of a port of Qt to Wayland, too. [131001920010] |How to find information about the system/machine in Unix? [131001920020] |I have always found it difficult to find information about the system itself in Unix, whether it be [131001920030] |
  • Which OS I am using (version number and all, to compare it with the latest available builds)?
  • [131001920040] |
  • Which Desktop Environment am I using? [131001920050] |If I am using KDE, most of the programs begin with a K and I can say I am using KDE, but there should be some way to query this, say from a script.
  • [131001920060] |
  • Which kernel version am I using? [131001920070] |(For example, I am using Fedora, and I want to know what Linux kernel version I am using)
  • [131001920080] |Basically, what I miss is a single point/utility that can get all this information for me. [131001920090] |Most of the times the solutions to the above would themselves be OS specific. [131001920100] |Then, you are stuck. [131001930010] |maybe you can use [131001930020] |to get information about the kernel version and which OS you are using [131001940010] |As @milk pointed out, you can use uname -a and that will tell you information on all the UNIXes I have access to. [131001940020] |For example, on Linux: [131001940030] |On FreeBSD: [131001940040] |On OpenSolaris: [131001940050] |As far as the desktop environment question goes, you should be able to echo $DESKTOP_SESSION in KDE or GNOME and get back the right answer. [131001940060] |If you want to find out what distro you're running, a cheater's shortcut is to cat /etc/*-version /etc/*-release. [131001950010] |In addition to uname -a, which gives you the kernel version, you can try: [131001950020] |Most Desktop Environments like GNOME or KDE have an "about" or "info" menu option that will tell you what you use currently, so no commandline needed there really. [131001960010] |Not totally foolproof, but halfway there: [131001960020] |(I can't help it if you feel like using gnome-panel under kwin, though ;-) Also, I find this very useful under Linux: [131001970010] |Building on everyones post above, maybe run a simple script [131001970020] |running that gives me [131001980010] |Run gnome-system-monitor (package is the same name in Debian, Ubuntu, and Fedora), and click on the System tab: [131001980020] |The desktop thing is a little hard because you can have multiple ones installed, and can run one package belonging to one desktop on a different desktop. [131001980030] |Also, running printenv DESKTOP_SESSION on my Debian system just outputs default (but it works well on Ubuntu and Fedora). [131001990010] |Hide processes from other users based on groups (under Linux)? [131001990020] |Is it possible to configure process hiding for certain user groups under a linux system? [131001990030] |For example: Users from group X should not see processes owned by users from group Y in ps/top or under /proc. [131001990040] |Is it possible to configure such a setup with SELinux? [131001990050] |(I vaguely remember a similar feature in the funny grsecurity patch set - but IIRC, it was more generic - and besides, I want to configure a stock linux distro without having to maintain a custom kernel.) [131001990060] |Edit: For better illustration, Solaris 10 has a similar feature. [131001990070] |The example is not that generic, but one can configure that a user or some users can only see information of their own processes in ps etc. [131002000010] |Without a rootkit, or without hacking the kernel to specifically allow that behavior, there are not any pre-packaged options. [131002000020] |If these are processes launched from code you have access to then you may be able to recompile it while altering the argv[0] argument passed into the program. [131002000030] |This could effectively change the name to something benign and thus "hide" it from anyone checking top or ps, etc. [131002010010] |Actually, SELinux seems to allow such configurations: [131002010020] |From the first Howto: [131002010030] |This time, you will see all processes on the system regardless of the domain they are in. [131002010040] |When in sysadm_t domain, you have access to other domains which the user_t domain does not. [131002010050] |From the second Howto: [131002010060] |The third line allows staff_t to run ps and see processes in the unprivileged user domains. staff_t is able to run ps and see everything in user_t and other user domains if any, whereas user_t can not. [131002020010] |What is sendmail referring to here? [131002020020] |When I install sendmail from the debian repos, I get the following output: [131002020030] |Can someone please tell me what this means, what I need to do to qualify my hostname? [131002030010] |It's referring to this page from the readme, which tells you how to specify your hostname. [131002030020] |It's warning you that your hostname won't work outside your local network; sendmail attaches your hostname as the sender of the message, but it's going to be useless on the other end because people outside your local network can't find the machine ixtmixilix. [131002030030] |You should specify a hostname that can be resolved from anywhere, like ixtmixilix.example.com [131002040010] |This output refers to a Fully-qualified domain name (FQDN). [131002040020] |Which is either an IP address or a domain name (something with a dot in it). [131002050010] |Just installed openSUSE 11.3, and after 5 seconds , my keyboard goes to sleep for 1-2 characters??? [131002050020] |My keyboard skips one or two characters, whenever I stop typing for 5 seconds or more. [131002050030] |Since I just installed 11.3 openSUSE, I don't know if this issue is an improper configuration, a bug in 11.3, or my keyboard failing. [131002050040] |It doesn't matter what application I am running, or what keys are pressed. [131002050050] |Keyboard failure doesn't seem likely. [131002050060] |I cannot find anything in either yast or personal preferences that might fix it. [131002050070] |Thus, I suspect something in SUSE, maybe the keyboard driver, but I am a not a Linux pro, and I am stumped. [131002050080] |It is very annoying, having to kkey first characters twice after pausing. [131002050090] |Thanks very much for any help. [131002060010] |Did you update your kernel? [131002060020] |There was an update last week that introduced this error: http://lwn.net/Articles/404712/ It should be fixed sometime soon. [131002060030] |In the meantime you can downgrade to 2.6.34-12.3 [131002070010] |Zsh (the Z shell) is a unix shell. [131002070020] |On the scripting front, zsh and incorporates many of ksh's programming features. [131002070030] |Zsh's syntax resembles but is not fully compatible with Bourne-style shells, though zsh has Bourne and ksh emulation modes with compatible syntax and behavior. [131002070040] |Zsh's advanced features include many extensions to variable expansion and globbing, associative arrays and more. [131002070050] |For interactive use, zsh's features include advanced line edition, advanced programmable completion, spelling correction, themable prompts and more. [131002070060] |Zsh is highly customizable, with many options and tuning possibilities. [131002070070] |The zsh distribution includes add-ons in the form of loadable modules and functions: zmv for batch file renaming, the FTP client zftp, regular expressions, terminal handling, and many more. [131002070080] |

    Links and documentation

    [131002070090] |
  • Zsh web page
  • [131002070100] |
  • zsh-lovers — tips, tricks and examples for the Z shell
  • [131002070110] |

    Related tags

    [131002070120] |
  • shell Many shell-agnostic questions are of interest to zsh users.
  • [131002070130] |
  • wildcards (or globbing): matching files based on their name
  • [131002070140] |
  • command-history a history of commands that can be navigated with the Up and Down keys, searched, etc.; also a recall mechanism based on expanding sequences beginning with !.
  • [131002070150] |
  • autocomplete completion of partially-entered file names, command names, options and other arguments.
  • [131002070160] |
  • prompt showing a prompt before each command, which many users like to configure.
  • [131002070170] |

    Further reading

    [131002070180] |
  • What features are in zsh and missing from bash, or vice versa?
  • [131002070190] |
  • rebuild auto-complete index (or whatever it's called)
  • [131002070200] |
  • How to edit command line in full screen editor in ZSH?
  • [131002070210] |
  • zsh: trouble batch-renaming files with zmv
  • [131002080010] |The interactive interface to your shel [131002090010] |Prevent disk renumbering on reboot in OSX [131002090020] |I have 3 physical drives in my Mac Pro with OSX 10.6.4. [131002090030] |Occasionally after rebooting the machine, the disk numbering changes such that the /dev/disk# does not reference the same drive as it did before the reboot. [131002090040] |Example [131002090050] |After rebooting the mapping might be [131002090060] |Even more confusing is that the remapping is not consistent. [131002090070] |For most stuff this is irrelevant. [131002090080] |However I also have Parallels installed to allow access to the BootCamp partition from within OSX. [131002090090] |Parallels uses the /dev/disk# path in it's configuration file so, after rebooting OSX I launch Parallels and it tells me that the disk is no longer present. [131002090100] |Is there a way to tell OSX to always assign a given drive to /dev/disk0? [131002100010] |You can use the UUID to tie down the mount points. [131002100020] |
  • Find out the UUID of each disk using the command [131002100030] |
  • Add the device in your /etc/fstab by specifying the device along with UUID (rather than /dev/disk*: [131002110010] |Macrumours Link [131002120010] |What RPMs do I need for timeconfig? [131002120020] |I've got setuptools set up and have read through the list of what's in /etc/setuptools.d [131002120030] |I'm interested in installing timeconfig as well, but I only need the TUI version (no GUI). [131002120040] |Which RPMs do I need? [131002120050] |(I'll be including these RPMs in a CentOS ISO installation) [131002130010] |You need the package system-config-date. [131002130020] |In CentOS it is not installed by default but you can install it by typing [131002130030] |and that should get you the tui tool you need which you can run by typing [131002140010] |If you can make a reasonable guess as to where a command is located, yum can tell you what package it's in. [131002150010] |OpenVMS/vax 7.3 on a VAXstation 3100 Model 76 [131002150020] |I know this is not UNIX related, but I believe this place aggregates the most expertize, that can help me on this issue. [131002150030] |I have an OpenVMS/vax 7.3 CDROM, and I'd like to install that onto my VAXstation 3100 Model 76, but don't know quite how. [131002150040] |It boots fine from the CD, but I don't know how to install that onto my disks. [131002150050] |The CDROM drive designation is DKB0, and I've got two hard drives: DKA100, and DKA200. [131002160010] |Can you recommend a GUI text editor for a developer (features needed are inside)? [131002160020] |F-cked up with all IDE bloatware (for my purposes they are all overcomplicated and inconvenient), I came to an idea, that I'd probably better use a good editor than an IDE. [131002160030] |I DON'T need projects, I don't need build management (I'd prefer to build manually, from command line, and write build scripts myself), I don't need perspectives, workspaces, modules, etc. [131002160040] |I need (in importance descending order) [131002160050] |
  • Nice GUI. [131002160060] |(I am sorry to say this to be the first priority, but that's my taste, without it I feel uncomfortable and go unproductive). [131002160070] |Please don't offer VIM (with no GUI) or [X]EMACS (with ugly GUI). No weird key scheme (like VIM has), no command modes (or optionally enablable and unimportant in the editor's usage), etc.
  • [131002160080] |
  • Manually-definable foldable regions (like in c#) (defined by special macroses, escaped by (any language's) comments) in any language. [131002160090] |This is the most important requirement. [131002160100] |If I find an editor meeting this point alongside with 1st one, I'd be happy already. [131002160110] |In Windows, as far as I can remember, UltraEdit used to have this facility, but I am not sure (update: now I've installed UEx anc couldn't find such a feature there).
  • [131002160120] |
  • Simple, but swiss-clockwork-reliable refactoring, better to say sort of "multifile search-and-replace on steroids".
  • [131002160130] |
  • Syntax highlighting.
  • [131002160140] |
  • Corresponding open/close parentheses/braces/tags/quotes/etc. pairs highlighting.
  • [131002160150] |
  • Autocompletion. [131002160160] |Probably simple, dictionary-based. [131002160170] |Would be very nice if it could wok as an IDE, showing me class members after I put a dot and press Ctrl+Space, but I can afford lack of this feature if 1-4 features are there.
  • [131002160180] |
  • Code snippets / macrosses.
  • [131002160190] |Explanation of point 2: [131002160200] |Those who are familiar with C# possibly know of #region/#endregion directives. [131002160210] |I can place them anywhere in code, and the editor will offer an option to fold the block delimited into one line (with a title specified as the starting directive argument) and unfold it on demand (much as most of modern editors can do with language blocks, like function bodies for example, but I'd like to be able to do this with any particular block of code I want). [131002160220] |IMHO it could be pretty easily implemented (in editors, that have already implemented code folding for language blocks) for ANY language, no language syntax analysis required. [131002160230] |A region defining directives syntax can be provided by an editor, escaping those directives by a language's comment line syntax. [131002160240] |For example, NetBeans IDE has this functionality for Java, it is well described here: http://wiki.netbeans.org/FaqCustomCodeFolds But in NetBeans this, unfortunately, works only with Java (and, maybe, some other) language, and doesn't work, for example, with Scala. [131002160250] |I mostly code Scala, but, as I wrote, I'd wish, and can't see any reasons why couldn't be it made available as a language-agnostic feature - if the line contains "(whatever) #region" - this is a foldable region start, if there's something after "#region" in the line - this is the region title, if the line contains "(whatever) #endregion" - this is the region finish. [131002160260] |Just find a start and a corresponding finish and fold it. [131002160270] |User can replace "(whatever)" with any particular's language comment sign. [131002160280] |UPDATE: answer found (just to summarize and share an answer in a more informative form, I'll include it here): [131002160290] |There vere many good suggestions (I am going to experiment with SciTE and try learning EMACS and VIM when I'll have a proper mood). [131002160300] |Googling myself I've also find an interesting E-TextEditor (an open-source wxWidgets-based (means cross-platform, there were successful efforts to build and install it on Fedora 10 and on Ubuntu 9.04) Mac's TextMate clone for Windows). [131002160310] |But the answer for now, found thanks to fschmitt's suggestion, is Kate. [131002160320] |To get my point #2 (above, in the question) for Scala (easily adaptable for any other language the way I've explained), I had only to add 2 lines in "/usr/share/kde4/apps/katepart/syntax/scala.xml": [131002160330] |I've taken the idea from C# syntax definition file, cs.xml. [131002160340] |The only trick is that for this comment-aided hack to work these lines are to be placed before lines which define the language's comments. [131002160350] |And a pleasant surprise there: Kate does not depend on tons of KDE libraries as I used to suppose - in classic (Gnome) Ubuntu 10.10 "apt-get install kate" has only downloaded one humble (less than a MiB) package. [131002170010] |If you like Ultra Edit, why don't you try its Linux version? [131002170020] |Otherwise, you might try Kate. [131002170030] |Although I don't know whether it fulfills you requirements, it is the most feature rich and configurable modern GUI editor I have seen up till now (apart from Emacs, which you explicitly don't want). [131002180010] |I don't know about all of your requirements, but two projects you should check out and try is Geany and SciTE. [131002180020] |Both of these projects sports lightweight, yet functional, editors that keep things simple. [131002190010] |I know you said you don't want funky hotkeys, but from what you want it really sounds like a feature list of GVIM. [131002190020] |Maybe it's worth using vimtutor to learn why (G)vim works like it does. [131002190030] |I was scared too at first but now I wouldn't wanna go back. [131002200010] |Well, I found NetBeans has some plugins for Scala. [131002200020] |It has plugins available for many other languages too. [131002200030] |Maybe you can give it a try. [131002210010] |Serve files over USB [131002210020] |Hello, [131002210030] |I would like to be able to serve a section of my box's file system over USB to another computer. [131002210040] |For example, if the files are on box A and I am reading from box B, then B would mount A, see those files, and mount them as a file system device (ie., like a thumb drive). [131002210050] |Ideally the solution would work for any Linux distro, but I will most likely be running this on Debian variants. [131002210060] |Please let me know if you need any more info. [131002210070] |Cheers. [131002220010] |I don't really see how USB fits in here? [131002220020] |Why don't you use SAMBA or NFS to share the files between those machines? [131002220030] |Maybe that doesn't work for some reason, so you should probably add a little more explanation... [131002230010] |I think this can be accomplished with a host-to-host USB cable and the Linux usbnet driver. [131002230020] |Hardware compatibility and details on how to set this up in Linux are given at: http://www.linux-usb.org/usbnet/ [131002240010] |From the information you've given, I surmise that: [131002240020] |
  • You have a black box device which you can communicate with only by plugging a USB mass storage device into it.
  • [131002240030] |
  • Physically plugging and unplugging a USB drive is not acceptable, you won't have physical access after deployment.
  • [131002240040] |If any of these assumptions is false, you'll have an easier time. [131002240050] |What you're looking for is a way to make a computer appear as a USB storage device. [131002240060] |In principle, this shouldn't require much electronics — I think the right gadget could be mass produced for no more than a couple USD plus shipping. [131002240070] |But I can't find a reference to the right gadget existing. [131002240080] |Merely using a USB computer-to-computer cable won't do the trick: these simulate an Ethernet network, and the black box doesn't speak Ethernet. [131002240090] |And USB-storage-to-LAN converters won't help, they go the wrong way round. [131002240100] |
  • You could design a robot arm that unplugs a USB stick from the black box and plugs it into a computer. [131002240110] |Now that the obvious but impractical suggestion has been made...
  • [131002240120] |
  • You could have the gadget designed, and write a driver for it. [131002240130] |But this might be out of your price range, especially if you don't need millions of units.
  • [131002240140] |
  • There may be a sophisticated NAS device that can talk to several computers over iSCSI and USB (those last two words are the difficult part).
  • [131002240150] |
  • Some mobile phones and PDAs can act as a USB storage device, and additionally have a GSM, wifi or Ethernet connection. [131002240160] |But they often act as storage devices only when switched off, so I don't know if there is one that could be used as a bridge or server.
  • [131002240170] |
  • Here's a discussion about a somewhat similar requirement. [131002240180] |The only possible solution it suggests is this USB-storage-to-wifi bridge, which looks like it would be suitable — but it's expensive.
  • [131002240190] |
  • There are USB switches (a.k.a. sharing hubs) that allow you to share a USB device between two computers. [131002240200] |You could use one to share a storage device between the black box and a computer. [131002240210] |The problem is that they usually require the user to press a button to switch between the two devices — but if you find one where the switch can be controlled remotely, you have a solution.
  • [131002250010] |Even if you solve the USB specific issues like making a USB host look like a USB device, you'll run into problems mounting the filesystem on two different devices at the same time. [131002250020] |If Box A has a drive (let's say /dev/sdb1) and it's mounted and using the files on /dev/sdb1, what happens when Box B mounts wants access to those files? [131002250030] |At the lowest level, USB is going to want to expect to deal with a device, not a filesystem. [131002260010] |Kernel segmentation fault (core dumped), how to diagnose ? [131002260020] |I have a fedora 13 x64 box I use at home for a storage server. [131002260030] |I use sshfs to mount my music from home and listen at work, I run my irssi client in screen on it for freenode communication and lately I appears to be popping up with protection faults from the kernel. [131002260040] |The message I receive: [131002260050] |My machine is: [131002260060] |Linux 2.6.34.7-56.fc13.x86_64 #1 SMP Wed Sep 15 03:36:55 UTC 2010 x86_64 GNU/Linux [131002260070] |It appears to be related to a usb device, because of the last sysfs file: /sys/devices/pci0000:00/0000:00.1d.2/usb8/devnum however I am not using an usb ports it is a headless desktop with all internal hard drives and a ethernet running to my switch. [131002260080] |Any help on this would be appreciated? [131002270010] |SSH Do not connect even with publickeys installed [131002270020] |Hey guys, [131002270030] |I'm trying to connect two servers. [131002270040] |I got the id_dsa.pub key from user john from server A and paste into authorized_keys of user mike from server B. [131002270050] |Then I tried to connect from server A to server B using mike login, however it is still asking for password. [131002270060] |In mike's .ssh/ directory I have only authorized_keys file, like this: [131002270070] |The admin guy from server B assured that having only this file it's enough to let us connect at B server. [131002270080] |Am I missing something? [131002270090] |Thanks guys! [131002270100] |EDIT: Here is the Log: [131002280010] |You may have just copied the key incorrectly. [131002280020] |Try this: [131002280030] |
  • On Server B(as mike): rm ~/.ssh/authorized_keys
  • [131002280040] |
  • On Server A(as john): ssh-copy-id -i /path/to/id_dsa.pub mike@serverb
  • [131002280050] |The ssh-copy-id command basically connects to the remote host (using password auth) and then edits authorized_keys appropriately. [131002280060] |I believe it is distributed with OpenSSH, if you are using something else, it may not be available. [131002290010] |Do you have access to the SSH logs on ServerB? [131002290020] |If not, can the admin send the relevant lines to you? [131002290030] |On ServerB, the permissions for make sure that you have the correct permissions as described in the SSH manpage: [131002300010] |On the client, type: [131002300020] |ssh-keygen -t rsa -b 4096 [131002300030] |enter ENTER when prompted for a password. [131002300040] |go to ~/.ssh and copy id_rsa.pub to the server. cat id_rsa.pub >>/home/username/.ssh/authorized_keys [131002300050] |Also on the server edit the /etc/ssh/sshd_config file to allow key-based authentication [131002300060] |and run /etc/init.d/sshd restart [131002300070] |then on the client-machine enter: ssh usernameOfTheUserOnTheServerWhereYouCopiedTheKeyToAuthorizedKeys@192.168.1.x [131002310010] |How do I mount a WD MyBook World network drive in linux? [131002310020] |I have a WD MyBook World NAS on my home network. [131002310030] |I currently use this for Time Machine backups for my Mac but I'd also like to use it as a backup location for my linux box which is running Ubuntu Server. [131002310040] |How can I mount this drive on the linux server so that my cron backups can use it as a backup destination? [131002310050] |I have configured the WD drive with a static IP address which I assume would be important in the solution. [131002320010] |According to the manual, the MyBook supports both the CIFS/SMB and the NFS protocols. [131002320020] |CIFS/SMB is the protocol natively used by Windows for accessing network drives. [131002320030] |You should be able to access the MyBook on a Linux/Unix system by using the smbclient or mount.cifs, e.g. to access (mount) the "public" folder on MyBook on the local directory /mnt you would issue (from a root terminal): [131002320040] |or, equivalently: [131002320050] |where: [131002320060] |
  • you can substitute "public" with "download" (to access the pre-defined download share) or any share name that you have created with the MyBook storage manager.
  • [131002320070] |
  • username/password can be those of any user that you have created on the MyBook storage manager interface; or just use -o guest instead of -o username=...,password=... to specify "Guest" access.
  • [131002320080] |Access by the NFS protocol is not enabled by default; you have first to enable it in the "Advanced" tab of the MyBook storage manager, then you can mount the disk shares via NFS with: [131002320090] |mount -t nfs ip.address.of.mybook/nfs/public /mnt [131002320100] |Again, "public" can be any defined share name. [131002330010] |Edit: I had in mind that the WD MyBook World is only accessible by the MioNet software; however, the links may still be helpful: [131002330020] |There is good and bad news. [131002330030] |Bad news first: The official statement of the vendor is the following: [131002330040] |Does MioNet work with Macintosh or Linux computers? [131002330050] |Currently, MioNet works with only Windows-based computers. [131002330060] |However, our platform will be extended to these operating systems in the future. [131002330070] |Mionet FAQ [131002330080] |Good News: The WD MyBook World runs a linux system which can be "opened". [131002330090] |You can enable ssh and install additional packages: [131002330100] |The system partition has 2.8GB (only 260 MB is occupied). [131002330110] |This means that you have a lot of resources for various improvements. [131002330120] |Here are two guides to open the NAS: [131002330130] |Hacking Western Digital MyBook World Edition Hacking WD MyBook World Ed [131002330140] |The chapter "MyBook World Edition acting as a NFS server" could be interesting. [131002340010] |How to run “sudo apt-get update” through proxy in commandline? [131002340020] |In my office I want to update and download through wget and here they are using a proxy. [131002340030] |How can I get wget to use the proxy from the command-line? [131002350010] |Either export the "http_proxy" environment variable as in "export http_proxy=http://myproxy:port" or add [131002350020] |To /etc/apt/apt.conf. [131002350030] |See http://ubuntuforums.org/showthread.php?t=96802 [131002360010] |If your machine is behind a proxy running a Microsoft NTLM based web proxy you may need something like the (python based) ntlmaps to sit between wget/apt-get and the real proxy to do the authentication for you. [131002370010] |fdisk unable to open [131002370020] |I am having problems using fdisk to clear the partition table of my sd card. [131002370030] |The sd card is identified in the /dev folder when inserted into the sd card reader, but when the following command in run: [131002370040] |the response in the terminal is: [131002370050] |unable to open sde [131002370060] |I have also tried using sde1, which is the partition on the sd card, and it still failed. [131002370070] |How do I fix this? [131002380010] |Like, Falmarri indicated in his comment, you are not running fdisk as root. [131002380020] |The easiest way to do this, is to run: [131002390010] |Remove end of line characters from stdout? Multiple lines into a single line. [131002390020] |I have a script which outputs the following text. [131002390030] |This is the output from a Netopia 2210-02 ADSL2 modem. [131002390040] |How can I remove the end-of-line character for each line? [131002390050] |I would like the output to look something like this (Yes it's ugly): [131002390060] |I tried some solutions like this, but they don't work: [131002390070] |I also tried using tr. [131002390080] |I was expecting the following command to replace each newline character with the space character. [131002390090] |This would take the multiple lines and combine them into one long single line. [131002390100] |Instead, this only displays the last line of output. [131002390110] |It seems to overwrite each subsequent line with the next line of output. [131002390120] |Update: [131002390130] |Upon further examination, it looks like each line is preceded by a return character. [131002390140] |This shows up as ^M when using less. [131002390150] |So, I added two tr statements. [131002390160] |One to delete newline characters, one to delete the return character. [131002400010] |sed won't work (easily) because it operates on lines one at a time; you could do it, but it would involve copying the whole input into the hold buffer [131002400020] |tr actually should work the way you pasted it; are you sure the newlines are \ns? [131002400030] |You can simplify it a bit by deleting the newlines instead of converting them to spaces: [131002410010] |besides tr, some other methods you can use [131002410020] |awk [131002410030] |shell [131002410040] |sed [131002420010] |how to get IP from DHCP in network in redhat which is installed on VMware [131002420020] |I'm running Red Hat inside a VMware image (on a Windows XP machine). [131002420030] |I want to connect the Red Hat VM to our network; do I need to configure something inside VMware or inside Red Hat? [131002420040] |I don't have any IPs set to connect to the internet [131002430010] |Red Hat is the name of a company, the last distribution called just Redhat Linux was 9.0 in 2003. [131002430020] |Therefore I guess you are in fact running Redhat Enterprise Linux (RHEL). [131002430030] |If you run a recent version, i.e. RHEL 5.x, the network connections are configured using a program called system-config-network. [131002430040] |Normally, VMware should give the Linux system network access by means of a virtual network card out of the box, so the process should be self-explaining. [131002430050] |If you need a guide, you can follow generic instructions for getting networking running on RHEL. [131002430060] |See, e.g., http://www.cyberciti.biz/faq/rhel-centos-fedoracore-linux-network-card-configuration/ [131002440010] |Presuming that you have a DHCP server set up on your internal network, all you should need to do is to configure the VMware virtual NIC to be in bridged mode; this tells VMWare to act as a virtual bridge with respect to any packets the virtual machine sends out. [131002440020] |When I say a vitrual bridge, I mean a device that just crosses the border between virtual and physical. [131002450010] |What's the + in find /path/ -exec command '{}' + do? [131002450020] |What's the + in find /path/ -exec command '{}' + do? as opposed to find /path/ -exec command '{}' \; [131002460010] |From the man page: [131002460020] |-exec command {} + [131002460030] |This variant of the -exec action runs the specified command on the selected files, but the command line is built by appending each selected file name at the end; the total number of invocations of the command will be much less than the number of matched files. [131002460040] |The command line is built in much the same way that xargs builds its command lines. [131002460050] |Only one instance of `{}' is allowed within the command. [131002460060] |The command is executed in the starting directory. [131002470010] |The '+' makes one big command line out of all found files to minimize the number of commands to be run. [131002470020] |Given the case that a find command finds four files. [131002470030] |would produce [131002470040] |On the other hand [131002470050] |produces [131002480010] |Install g++ when having gcc (C only) -- RH6 [131002480020] |Hello all, [131002480030] |I have a Red-Hat 6 machine, which came with GCC but without g++. [131002480040] |The gcc version is 4.4.4 20100726 (this is what I got from gcc --version). [131002480050] |How can I get g++ working? [131002480060] |Currently, when trying to type g++ the shell prints "command not found". [131002480070] |Thanks in advance. [131002490010] |You need to install gcc-g++ : yum install gcc-c++ [131002500010] |Linux Editor to make video for elearning [131002500020] |Does anyone know a solution to create video courses on Linux, i.e: [131002500030] |
  • recording in the same time the videos from the webcam, the powerpoint / openoffice document, the annotations on the document (using electronic whiteboard) and my speech
  • [131002500040] |
  • a way to edit after creation to remove / add new video sequences
  • [131002510010] |Try using RecorditNow. [131002510020] |Can use ffmpeg or recordmydesktop as backends. [131002520010] |What is a Superblock, Inode, Dentry and a File? [131002520020] |From the article Anatomy of Linux File Systems by Tim Jones, I read that Linux views all the file systems from the perspective of a common set of objects and these objects are superblock, inode, dentry and file. [131002520030] |Even though the rest of the paragraph explains the above, I was not that comfortable with that explanation. [131002520040] |Could somebody explain to me these terms? [131002530010] |First and foremost, and I realize that it was not one of the terms from your question, you must understand metadata. [131002530020] |Succinctly, and stolen from Wikipedia, metadata is data about data. [131002530030] |That is to say that metadata contains information about a piece of data. [131002530040] |For example, if I own a car then I have a set of information about the car but which is not part of the car itself. [131002530050] |Information such as the registration number, make, model, year of manufacture, insurance information, and so on. [131002530060] |All of that information is collectively referred to as the metadata. [131002530070] |In Linux and UNIX file systems metadata exists at multiple levels of organization as you will see. [131002530080] |The superblock is essentially file system metadata and defines the file system type, size, status, and information about other metadata structures (metadata of metadata). [131002530090] |The superblock is very critical to the file system and therefore is stored in multiple redundant copies for each file system. [131002530100] |The superblock is a very "high level" metadata structure for the file system. [131002530110] |For example, if the superblock of a partition, /var, becomes corrupt then the file system in question (/var) cannot be mounted by the operating system. [131002530120] |Commonly in this event fsck is run and will automatically select an alternate, backup copy of the superblock and attempt to recover the file system. [131002530130] |The backup copies themselves are stored in block groups spread through the file system with the first stored at a 1 block offset from the start of the partition. [131002530140] |This is important in the event that a manual recovery is necessary. [131002530150] |You may view information about superblock backups with the command dumpe2fs /dev/foo | grep -i superblock which is useful in the event of a manual recovery attempt. [131002530160] |Let us suppose that the dumpe2fs command outputs the line Backup superblock at 163840, Group descriptors at 163841-163841. [131002530170] |We can use this information, and additional knowledge about the file system structure, to attempt to use this superblock backup: /sbin/fsck.ext3 -b 163840 -B 1024 /dev/foo. [131002530180] |Please note that I have assumed a block size of 1024 bytes for this example. [131002530190] |An inode exists in, or on, a file system and represents metadata about a file. [131002530200] |For clarity, all objects in a Linux or UNIX system are files; actual files, directories, devices, and so on. [131002530210] |Please note that, among the metadata contained in an inode, there is no file name as humans think of it, this will be important later. [131002530220] |An inode contains essentially information about ownership (user, group), access mode (read, write, execute permissions) and file type. [131002530230] |A dentry is the glue that holds inodes and files together by relating inode numbers to file names. [131002530240] |Dentries also play a role in directory caching which, ideally, keeps the most frequently used files on-hand for faster access. [131002530250] |File system traversal is another aspect of the dentry as it maintains a relationship between directories and their files. [131002530260] |A file, in addition to being what humans typically think of when presented with the word, is really just a block of logically related arbitrary data. [131002530270] |Comparatively very dull considering all of the work done (above) to keep track of them. [131002530280] |I fully realize that a few sentences do not provide a full explanation of any of these concepts so please feel free to ask for additional details when and where necessary. [131002540010] |Note that these terms aren't Linux specific but file system specific. [131002540020] |Most filesystems used by current Unix and Unix like systems are either derived or inspired by the original Unix filesystem which defined the superblock and inode idioms. [131002540030] |Linux can also mount several filesystems with which there is no notion of superblock and/or inode, the most common being FAT. [131002540040] |Another one, ZFS, doesn't use superblocks but überblocks. [131002550010] |File [131002550020] |A file just means a bunch of bytes arranged in a certain order. [131002550030] |It's what normal people call the contents of a file. [131002550040] |When Linux opens a file, it also creates a file object, which holds data about where the file is stored and what processes are using it. [131002550050] |The file object (but not the file data itself) is thrown away when the file is closed. [131002550060] |Inode [131002550070] |An inode (short for "index node") is a bunch of attributes about a file that Linux stores. [131002550080] |There is one inode for each file (though with some filesystems, Linux has to create its own inodes because the information is spread around the filesystem). [131002550090] |The inode stores information like who owns the file, how big the file is, and who is allowed to open the file. [131002550100] |Each inode also contains a number unique to the filesystem partition; it's like a serial number for the file described by that inode. [131002550110] |Dentry [131002550120] |A dentry (short for "directory entry") is what the Linux kernel uses to keep track of the hierarchy of files in directories. [131002550130] |Each dentry maps an inode number to a file name and a parent directory. [131002550140] |Superblock [131002550150] |The superblock is a unique data structure in a filesystem (though multiple copies exist to guard against corruption). [131002550160] |The superblock holds metadata about the filesystem, like which inode is the top-level directory and the type of filesystem used. [131002560010] |Why can't Rhythmbox play most of the files from my mt-daap share? [131002560020] |I have the Firefly Media Server (mt-daap) set up on an Ubuntu 10.10 VM, and I Ubuntu 10.10 set up on my laptop. [131002560030] |I am running Rhythmbox and using that to play the music files off the daap share. [131002560040] |Unfortunetly, very few of the files play -- Rhythmbox just skips right over them and jumps to the next file. [131002560050] |It has occasionally asked me to install a codec, and everytime it has asked I have authorized it to. [131002560060] |Almost all the files are m4a files, both the ones that play as well as the ones that don't/ The output of file for one that plays is: [131002560070] |ISO Media, MPEG v4 system, iTunes AAC-LC [131002560080] |The file command produces the same output for files which won't play. [131002560090] |How can I troubleshoot this further / how can I make Rhythmbox play these other files? [131002570010] |Try installing ubuntu-restricted-extras. [131002570020] |Ubuntu can't play MP3's and other closed-source encoders (AAC is one of them). [131002570030] |You might even have to add a repository, but since I always enable all of those repos, this command worked for me: [131002570040] |If you don't like the CLI too much, click here to open up Software Installer and do it via a GUI interface: apt:ubuntu-restricted-extras?section=universe?section=multiverse. [131002570050] |Good luck! [131002570060] |Also, if you're planning to play DVD's too, you might need to install the DVD decoders, as they are not included by default. [131002570070] |To do that, run this (no GUI here): [131002570080] |I'm running out of ideas, but maybe these packages would work? [131002570090] |I did some research, and these seemed to fix the problems you're having back in 2007, so the versions might have changed. [131002570100] |If you're up to installing more random packages in a frantic attempt to play Apple's ridiculous format, here you go: [131002570110] |Good luck, once more. [131002580010] |Turns out this was an issue with mt-daapd instead of with Rythmbox. [131002580020] |I deleted the mt-daapd database cache and restarted the server, and after rebuilding the cache all the files now play. [131002580030] |I'm sure installing all the software Blender mentioned helped! [131002590010] |Is it possible to make a Microsoft LifeCam HD-5000 work under linux? [131002590020] |I am trying to set up a virtual machine which will act as a home security system. [131002590030] |(If you've chatted with me in The Tavern, you may know why...) [131002590040] |I purchased two USB webcams (Microsoft LifeCam HD-5000) and am trying to get them to work with Motion. [131002590050] |However when I connected them to my Ubuntu 10.10 VM, no /dev/video devices were created. dmesg said: [131002590060] |There's a lot of results on Google for "uvcvideo: Failed to query (129) UVC probe control : -110 (exp. 26).". many people were saying to unload the uvcvideo module and reload it, because it loads before the usbaudio module. [131002590070] |But no amount of unloading and reloading worked. [131002590080] |A custom compile of the uvcvideo.ko module was suggested but the link to the source was dead. [131002590090] |Is there any way to make these webcams work under a *nix-like system? [131002590100] |Please note it does not have to be Ubuntu, I was setting up a brand new VM for this purpose so I am open to any unix-like OS, be it Fedora, CentOS, a BSD flavor or even Open Solaris or similar. [131002600010] |Here are two links, one is from Mint-linux saying it works in Mint. [131002600020] |There are two videos on Youtube showing it being used with Mint and Ubuntu. [131002610010] |Turns out the issue was VMware. [131002610020] |No matter how hard I tried I couldn't make the camera work inside a virtual machine under VMware Server 2.0. [131002610030] |Linux Mint was the only distro which even recognized it, and even then I kept getting errors that the camera could not be opened / IO errors. [131002610040] |Installing uvcvideo, cheese and motion directly on the host worked fine. [131002620010] |Is there any Virus attack in Linux? [131002620020] |Is there any virus attack on any of the current distributions of Linux? [131002620030] |if there is any, how was it solved? have they used any anti virus programs which are available now? [131002630010] |There is a worm going around for an exim4 vulnerability in Debian: http://blog.bytemark.co.uk//2010/12/12/fresh-worm-food [131002640010] |Why is GDM 2.20 still in Squeeze? [131002640020] |Both gdm (based on 2.20) and gdm3 (based on 2.30) are available in Debian Squeeze. [131002640030] |Supposing that gdm3 should replace gdm, why are they both still supported? [131002650010] |Googling easily leads to a message on a Debian mailing list which is in fact Debian bug #578704, a proposed addition to the release notes (snipped): [131002650020] |Since the rewrite has absolutely zero compatibility with previous versions, it will not be upgraded in place. [131002650030] |Therefore, while newly installed systems will get GDM 2.30 by default for squeeze, those upgrading from lenny will keep GDM 2.20. [131002650040] |The 2.20 version will be dropped after the squeeze release. [131002660010] |How to see disk details like manufacturer in Linux [131002660020] |With sfdisk -s I can see the disk capacity as follows: [131002660030] |How do I see disk details like disk manufacturer? [131002660040] |I tried hdparm, but got an error: [131002670010] |Try these commands: [131002670020] |You may have to install hwinfo. [131002670030] |Concerning hdparm: hdparm(8) says: [131002670040] |and: [131002680010] |You could read the disk properties directly through sysfs, also check the other files/dirs in /sys/class/block/sda/device/ (replace sda with drive you need). [131002690010] |try running "smartctl -a /dev/hda" (could be sda in your case, cat /proc/partitions will show you the device type to use) [131002700010] |Maintaining `/etc/hosts` for hosts on DHCP [131002700020] |On my local DHCP network I have different PC's that I need to access remotely. [131002700030] |Problem is that their IP's change. [131002700040] |Sometimes I plug my laptop and netbook into other people's DHCP networks. [131002700050] |My current solution is to upate the /etc/hosts file everytime the target IP's change. [131002700060] |My /etc/hosts file looks like this: [131002700070] |Is there a way to bypass all that admin? :) [131002700080] |For example, could my computers broadcast their IPs on the LAN? or something like that. [131002700090] |Windows does something like that, which allows you to refference a computer on the network with "\\COMPUTER_NAME" [131002710010] |It depends on what is doing the DHCP? [131002710020] |Most home routers use dnsmasq and you can use that as your local DNS server. [131002710030] |You just need to set dnsmasq to return itself as the DNS server. [131002710040] |Next, you need to make sure that your PCs broadcast a hostname during the DHCP request. [131002710050] |Then, voila, you should be able to resolve all your local machines through the DNS/DHCP server. [131002720010] |Depending on what you want to accomplish, you could set up avahi, which can broadcast the existence of a sshd service on your machine. [131002720020] |Be careful in 'foreign' networks though... [131002730010] |Is it possible to control which monitor is considered the primary monitor? [131002730020] |I just added a 2nd monitor and I ran into that oh so typical issue where the monitors are swapped. [131002730030] |Apparently, the 2nd monitor has been identified as "monitor 0" by X.org, but it's # 2 according to the ATI configuration applet. [131002730040] |(The applet numbers the monitors starting with 1, not 0.) [131002730050] |That said, this 2nd monitor is the first one listed by the applet. [131002730060] |This concerns me, as I have run into issues on Windows with dual-monitors swapping randomly after reboots. [131002730070] |Moving the Gnome panels over was easy enough, if not exactly obvious. [131002730080] |However, I wonder about the possibility of other things using "monitor 0" when, in this case, I would expect them on "monitor 1." [131002730090] |So, can I control which monitor is considered primary? [131002740010] |Often your monitor setup can be found in the Xorg configuration file /etc/X11/xorg.conf. [131002740020] |However, many modern distributions (such as recent Ubuntu releases) try to avoid using a configuration file, since maintaining it can be a pain. [131002740030] |You can create this file initially by running: [131002740040] |From there you can make further customizations. [131002740050] |The Arch wiki has an article that should help with making customizations. [131002740060] |If you want to change your primary monitor without editing xorg.conf you can try the following: [131002740070] |Here XXXX should be replaced by the output you want to be primary. [131002740080] |You can run [131002740090] |To see the current configuration and see what output devices are available. [131002740100] |Typically these will have names like "VGA1", "LVDS1", or other names that refer to the connection that is used. [131002740110] |Setting the monitor as primary will typically move your panels over as well, which is nice if you are using a laptop and want to change which monitor is the primary monitor multiple times a day. [131002740120] |I find this a lot nicer than creating an xorg.conf file, but my monitor configuration changes multiple times a day. [131002750010] |OpenBSD is a BSD variant with a strong emphasis on security. [131002750020] |

    Philosophy

    [131002750030] |The OpenBSD project emphasizes security and has long been a proponent of cryptography. [131002750040] |OpenSSH, the most common implementation of SSH, is produced by the OpenBSD project. [131002750050] |Other goals of the OpenBSD project include freeness, transparency (all development work is public), and standard compliance. [131002750060] |

    Releases

    [131002750070] |OpenBSD releases a new version approximately every six months. [131002750080] |

    Documentation

    [131002750090] |
  • Documenation and FAQ
  • [131002750100] |
  • Hardware support
  • [131002750110] |
  • Installation guide
  • [131002750120] |
  • Security information
  • [131002750130] |
  • Bug tracker
  • [131002750140] |
  • Additional packages (ports)
  • [131002750150] |
  • Manual pages, e.g. man(1)
  • [131002750160] |
  • Mailing lists
  • [131002750170] |

    Common tasks

    [131002750180] |
  • Install a package: pkg_add (requires PKG_PATH to be set)
  • [131002760010] |FTP client with a good GUI? [131002760020] |I love linux because I get control over my system. [131002760030] |But I do herald from the school of mac, where things are simple, beautiful, and powerful. [131002760040] |I like it that way, as opposed to having lots of knobs and levers and everything. [131002760050] |Does anyone know of a strong FTP client for linux that is in the vein of Panic's Transmit? [131002760060] |It's my choice FTP software in Mac OS, but I doubt I need to convince anyone here that I don't want to DEVELOP web apps in OS X. It's a pain, imo. [131002760070] |Currently I use Filezilla. [131002760080] |It works fine. [131002760090] |But it's UI is a mess, imho. [131002770010] |Since you're using Gnome on Ubuntu, why not use the default file manager (Nautilus)? [131002770020] |Under Ubuntu 10.04, choose “Connect to Server” in the Places menu, select “Public FTP” or “FTP (with login)” as the service type, enter the server name and other parameters (you can define bookmarks in this dialog box too), and voilà. [131002780010] |I don't use FTP a lot, but when I do I use FireFTP - a firefox extension. [131002780020] |It's small, light and does job well enough [131002790010] |You could try gftp. [131002790020] |It's a simple client but it does the job well. [131002800010] |Unix users, groups, and permissions [131002800020] |I don't understand unix users, groups, permissions, etc. [131002800030] |For example, things managed by the chmod, chgrp, usermod, groupadd, etc. commands. [131002800040] |How do all these things work? [131002810010] |I'd start here: Filesystem Permissions [131002820010] |It's all a method of granting various access to a file. [131002820020] |User is an individual user. [131002820030] |Use this when you want to give one person and only one person access. [131002820040] |Group is more than one user. [131002820050] |Use this when you want to give several people access. [131002820060] |Put them all in a unique group and set that as the group owner. [131002820070] |Other is for anybody who isn't the user or group owner. [131002820080] |A file always must have a user owner and a group owner. [131002820090] |Often each user will have a group named after them with only them as a member. [131002820100] |This way you can have a file that is truly owned by a single individual. [131002820110] |The permissions are as follows [131002820120] |
  • R -- Allows a user to read the contents of the file
  • [131002820130] |
  • W -- Allows a user to write to the file
  • [131002820140] |
  • X -- Allows a user to execute a file as a program
  • [131002820150] |R and W are probably pretty self explanatory. [131002820160] |X may be a little confusing. [131002820170] |In some situations you only want certain users to execute certain programs. [131002820180] |For example, perhaps you don't want regular users to execute fdisk or format. [131002820190] |Removing the X permission from other will allow you to restrict it like that. [131002820200] |File permissions when listed are displayed as something like rwxr-xr-x. [131002820210] |This is actually three groups of permissions. [131002820220] |The first three are for the user owner. [131002820230] |The second three are for the group owner and the last three are for all other users. [131002820240] |A letter indicates the permission is granted, while a dash indicates that permission is denied. [131002820250] |In the example I used the user owner can read the file, write new contents and execute the file as a program. [131002820260] |Group and other however may only read and execute. [131002820270] |Some common "gotchas" [131002820280] |
  • Making a file write only (-w-) is probably not what you want
  • [131002820290] |
  • In order to execute you must also have read. [131002820300] |That is, --x is useless on a file, it must be r-x.
  • [131002820310] |
  • There are other permissions than these which can be stored in ACLs. [131002820320] |If your operating system and/or filesystem support POSIX, NFSv4 or extended ACLs you may need to also check permissions there
  • [131002820330] |
  • Permissions as they apply to directories is slightly different, but close enough that you don't need to worry about that for now except that you should always enable r and x together on directories.
  • [131002830010] |How to install Iceweasel 4 on Debian? [131002830020] |I see that Iceweasel 4 from http://mozilla.debian.net/ repository is broken (depends on non-existent version of SQLite). [131002830030] |Is there a working repo out there? [131002830040] |[update] I'm using Debian Squeeze, and the version of SQLite required by Iceweasel 4 hasn't yet migrated there (it's only in Debian Sid). [131002840010] |I got this nice guide, but it's dated, so the broken-ness persists. [131002850010] |What's your version of Debian? [131002850020] |If you're running testing, use apt-pinning to add unstable to your sources and mark it at a lower priority. [131002850030] |Then add experimental to your sources. [131002850040] |Now the mozilla.debian.net packages should be installable. [131002860010] |A nicer guide here! :D [131002870010] |How do you choose which monitoring application to use? [131002870020] |Having a system for collecting performance statistics can be extremely useful. [131002870030] |In the past, I've used Munin for this, and it has been invaluable in analyzing bottlenecks and various other issues. [131002870040] |I was recently made aware of collectd, which seems very similar to Munin. [131002870050] |What monitoring applications are available and should be considered (other than Munin and Collectd), and how do you choose which one to use? [131002880010] |Munin is a data collector and visualizer (grapher) tool. [131002880020] |It is easy to set up. [131002880030] |Easy to use, but it uses too much resources and does not scale well. [131002880040] |The default collection interval is 5min and it is not easy to change that, because it will overload your machine and some plugin has problems if you do that anyway. [131002880050] |The plugins are executed (forked) every time when data collection occurs which is expensive. [131002880060] |It has networked setup. [131002880070] |You have to set up a local server and node even if you use one machine. [131002880080] |Collectd is a data collector tool only. [131002880090] |You can choose 3rd party soultions to graph the collected data, but it does not work out of the box. [131002880100] |It has many plugins, mostly written as a C module which gets started once when you start the daemon. [131002880110] |You can change the collection interval and you can get fine grained statistics. [131002880120] |It can collect data locally or via the network. [131002890010] |My favorite performance monitoring analysis tool is SGI's open source Performance CoPilot (PCP). [131002890020] |For a single system, it might be overkill - for a set of enterprise systems, it's fantastic. [131002890030] |PCP offers historical data, a networked configuration, and an alarm system which is incomparable in open source (or just about anywhere else). [131002900010] |My opinion is that zabbix rules. [131002900020] |It's powerful and user friendly. [131002900030] |You don't need any plugin or third party in order to make it work. [131002900040] |You can find lots of other suggestions in this post at server fault. [131002910010] |Can I make `cut` change a file in place? [131002910020] |The man page doesn't give me much hope, but I'm hoping it's an undocumented (and/or GNU-specific) feature. [131002920010] |I don't think that is possible using cut alone. [131002920020] |I couldn't find it in the man or info page. [131002920030] |You can do something such as [131002920040] |mktemp makes you a relatively safe temporary file that you can pipe the cut output into. [131002930010] |You can't. Either use ed or GNU sed or perl, or do what they do behind the scenes, which is to create a new file for the contents. [131002930020] |ed, portable: [131002930030] |GNU sed: [131002930040] |Perl: [131002930050] |cut, creating a new file (recommended, because if your script is interrupted, you can just run it again): [131002930060] |cut, replacing the file in place (retains the ownership and permissions of foo, but needs protection against interruptions): [131002930070] |I recommend using one of the cut-based methods. [131002930080] |That way you don't depend on any non-standard tool, you can use the best tool for the job, and you control the behavior on interrupt. [131002940010] |The moreutils package from ubuntu (and also debian) has a program called sponge, which sort-of also solves your problem. [131002940020] |From man sponge: [131002940030] |sponge reads standard input and writes it out to the specified file. [131002940040] |Unlike a shell redirect, sponge soaks up all its input before opening the output file. [131002940050] |This allows constricting pipelines that read from and write to the same file. [131002940060] |Which would let you do something like: [131002950010] |How to apply recursively chmod directories without affecting files? [131002950020] |After I apply chmod -R to a directory, permissions are changed for everything within (files and directories). [131002950030] |How can I change only directories, without modifying the files? [131002960010] |You can use find. [131002960020] |Where 750 is the mode you'd like to apply and "./" is the directory you will recursively search. [131002960030] |EDIT: Thanks to @Gilles and find(1), I've revised this for additional security and performance. [131002970010] |In this particular case you can use X instead of x which only adds the bits to directories or files which already have the executable bit set for some user (i.e. chmod -R +X my_dir). [131002970020] |In general (e.g. if you wanted to make all directories readable without affecting the files), you could either use find with -type d or if you're using zsh (or bash 4 with shopt -s globstar) the **/ glob (both without passing the -R flag to chmod). [131002980010] |Running several commands in a screen-split [131002980020] |I have a few long running commands that I would like to run together in the same screen (same tab in the terminal app). [131002980030] |My current setup is like this: [131002980040] |However, it seems that tmux split-window actually splits the last split, so if I run several command this way, the first command gets half the screen, and the other commands get progressively smaller and smaller parts. [131002980050] |Is there a simpler way that runs all commands in equal-sized splits? [131002990010] |I wrote a small python script to figure out the proper window sizes [131002990020] |usage: [131002990030] |EDIT: [131002990040] |Now a github gist: https://gist.github.com/785030 [131003000010] |Re hardlink and old rsnapshot backups [131003000020] |I changed my naming scheme on rsnapshot from localhost to my actual host name, unfortunately this 'caused hardlinks to not be made in the next backup. [131003000030] |Is there any way that I can relink my backup so that I'm not wasting space on my backup drive? [131003010010] |I made a Perl script that does something similar to what you're talking about: [131003010020] |http://pastebin.com/U7mFHZU7 [131003010030] |Basically, it just traverses a directory, calculating the SHA1sum of the files in it, hashing it and linking matches together. [131003010040] |It's come in handy on many, many occasions. [131003020010] |shell scripts that respond to console output [131003020020] |Disclaimer:: I am not an active shell scripter [131003020030] |How does one create a script that responds to console output? [131003020040] |For instance, I'm trying to setup a cron that periodically svnsync 's changes to my repository to a backup server every midnight. [131003020050] |The problem is, in order to sync, it prompts for authorization credentials. [131003020060] |svnsync sync accepts no options to specify a login thus a simple cron command is out. [131003020070] |I believe I can launch a script but I'm trying to figure out how to make it respond to console output. [131003020080] |For instance: [131003020090] |where ***< message >*** is the action I want the script to respond to. [131003030010] |expect might help. [131003030020] |There's a O'Reilly tutorial. [131003040010] |I was in doubt when you said "svnsync sync accepts no options to specify a login" so I checked the documentation and guess what, it does: [131003040020] |Those options should be enough for you to go back to a simple cron script. [131003040030] |Back into the case where you really can't specify such options, it is still easy to write a wrapper script that sends data to the program's stdin. [131003040040] |For example the following may work (where program is the program you wan to run, and text is a file where you store text to be sent to the program): [131003040050] |However, for authentication, programs are often written to ready from tty and not from stdin (for security reasons). [131003040060] |I'm not familiar with it, but you can still create a fake terminal in that case. [131003040070] |This is where expect comes into use. [131003050010] |Except this means putting passwords in clear in some script. [131003050020] |Not a very good idea. [131003050030] |Does svnsync not have options for ssh keys? [131003060010] |Two similar solutions: [131003060020] |
  • expect (as given by other answers), which requires TCL.
  • [131003060030] |
  • pexpect, written in pure Python.
  • [131003070010] |In Gnu Emacs how do I set up a global key to toggle the menu-bar? [131003070020] |Using Gnu Emacs 23.1.1 on Ubuntu 10.04... [131003070030] |I'm currently a total newb with emacs, and I've decided to go cold turkey with the Gnome menu bar. (but I do want it to be "available" for the teething transition period... tepid turkey? :) [131003070040] |So I'd like to know how to assign a key to toggle it on/off.. [131003070050] |I'm currently starting Emacs in full screen mode, with no menu-bar and no tool-bar I'm trying out a tabbar (when in X, but not when in terminal) .. [131003070060] |I'm almost getting used to it, but I find I feel completely lost sometimes without the menubar... [131003070070] |I've read that Emacs without the GUI paraphenalia is the way to go.. and I believe it!... the paradigms clash.. [131003070080] |But for now I'd like a menu-bar toggle, and it will be good experience to see how it is done.. [131003080010] |If you just want to toggle the menu bar, there's already a command for that (M-x menu-bar-mode). [131003080020] |To bind it to a key, you'd do: [131003080030] |If you want both the menu and toolbar to be toggled, you can do something like this: [131003080040] |It's probably worth looking at the Emacs FAQ (also found by C-h C-f). [131003080050] |Also, the SO info page for Emacs has a bunch of good links. [131003090010] |Is it possible to su without being prompted for a password? [131003090020] |I suspect su doesn't have any way to allow passing the password from the shell instead of being prompted for one, for security reasons (couldn't find anything in the MAN). [131003090030] |Is this true? [131003100010] |That's true, there is no way to have su(1) redirect its input from a place other than the tty. [131003100020] |But there are libraries and programs to simulate a terminal for automated scripting, for example, Expect. [131003100030] |Something similar to: [131003110010] |It's an incredibly bad idea, but if you really want to do it you can use sudo's NOPASSWD option: [131003110020] |Then user johndoe can do sudo su and wind up with a root prompt without ever being asked for a password. [131003110030] |I reiterate, though, that this is a REALLY BAD IDEA in most circumstances. [131003110040] |Sudo, preferably /without/ the nopasswd flag is significantly safer. [131003120010] |Alternative to Miro Video Converter for Linux? [131003120020] |Back in the Windows/Mac days, I used the wonderfully easy to use Miro Video Converter to convert videos I have into either the more open and Freerer Theora or WebM formats. [131003120030] |Two problems: [131003120040] |(1) No Linux binary that I could use. [131003120050] |(2) No advanced options that let me control the conversion process, such as embedding subtitles. [131003120060] |Is there an alternative FLOSS on Linux that does this? [131003120070] |Thanks! [131003130010] |ffmpeg does both, of course............ [131003140010] |I'd suggest a frontend to ffmpeg. [131003140020] |There are several out there, for example [131003140030] |
  • Sinthgunt
  • [131003140040] |
  • WinFF
  • [131003140050] |
  • Transcoder
  • [131003140060] |
  • HyperVideo Converter
  • [131003140070] |Sinthgunt looks the most promising to me - it looks relatively discoverable, and comes with loads of preset formats to convert into. [131003150010] |It may depend on the device/format targets, but HandBrake is also an interesting tool for such tasks. [131003150020] |It is a bit picky about output formats (only mkv and m4v), but works great if you can read those. [131003160010] |SCP uses encryption based on the Secure Shell (SSH) protocol to securely transfer files between hosts. [131003160020] |It is available in most Unix distributions via the scp command. [131003170010] |Mac OS X is a series of Unix-based operating systems and graphical user interfaces developed, marketed, and sold by Apple Inc. [131003170020] |Since 2002, Mac OS X has been included with all new Macintosh computer systems. [131003170030] |It is the successor to Mac OS 9, released in 1999, the final release of the "classic" Mac OS, which had been Apple's primary operating system since 1984. [131003200010] |A command-line system monitor tool that produces a frequently-updated list of processes. [131003210010] |How to add an iso file as APT source [131003210020] |Say I have this line in "/etc/fstab": [131003210030] |And I run these commands as root: [131003210040] |I expected the disk to be added as APT source, but nothing happens. [131003210050] |What's missing? [131003210060] |UPDATE: [131003210070] |I followed this advice and now I'm getting this: [131003210080] |This happens with or without "/etc/apt/apt.conf" changes. [131003220010] |here's what worked for me: [131003220020] |first, the line in /etc/fstab should look like this: [131003220030] |then, with the mount-point mounted, run apt-cdrom like this: [131003220040] |if apt still asks you to insert the disk, add these lines to apt.conf [131003220050] |I think you should find this will work for you too :) [131003230010] |RPM Build error : D: May free Score board((nil)) [131003230020] |I have a problem building , it fails with the error: [131003230030] |D: May free Score board((nil)) [131003230040] |What does this mean ? [131003230050] |I do not see any other errors appearing in the build before this so i am fairly stumped by the lack of information. [131003230060] |OS : FC 8 [131003230070] |Edit : FYI , it builds fine on FC10,13. [131003230080] |Edit2 : Sorry for the missing info guys. [131003230090] |I am trying to build a soap engine from apache - Axis2c. [131003230100] |I am creating an RPM for the same. [131003230110] |Here are the details of the spec file. [131003230120] |Build : [131003240010] |As I said in a comment: The error "D: May free Score board((nil))" is most likely not a useful diagnostic error, it just is the last line in the verbose output. [131003250010] |Determining what process is bound to a port [131003250020] |I know that using the command: [131003250030] |(or some variant of parameters with lsof) I can determine which process is bound to a particular port. [131003250040] |This is useful say if I'm trying to start something that wants to bind to 8080 and some else is already using that port, but I don't know what. [131003250050] |Is there an easy way to do this without using lsof? [131003250060] |I spend time working on many systems and lsof is often not installed. [131003260010] |netstat -lnp will list the pid and process name next to each listening port. [131003260020] |This will work under Linux, but not all others (like AIX.) Add -t if you want TCP only. [131003260030] |etc. [131003270010] |For Solaris you can use pfiles and then grep by sockname: or port:. [131003270020] |A sample (from here): [131003280010] |Another tool available on Linux is ss. [131003280020] |From the ss man page on Fedora: [131003280030] |Example output below - the final column shows the process binding: [131003290010] |On AIX, netstat &rmsock can be used to determine process binding: [131003300010] |netstat -p above is my vote. also look at lsof. [131003310010] |The cursor to a match, edit, the cursor to the next match, edit -- like in a directory? [131003310020] |Algorithmic blackout: [131003310030] |
  • problem: find the files that match
  • [131003310040] |
  • problem: stack/buffer the matches
  • [131003310050] |
  • move the cursor to the next file of the stack and thereby to the location of the match
  • [131003310060] |
  • repeat step 2
  • [131003310070] |Things I have used earlier to tackle the issue. [131003310080] |Vi/m: (the below works in an ubuntu server, perhaps configured by sysadmin but cannot get it work locally) [131003310090] |emacs: M-x grep Enter and then to have grep -r "[^|]*|[^|]*|[^|]*|.*" * but now in mystery. [131003310100] |How can you do the fast hierarchial edits? [131003310110] |shellesque: then I once created a wild one-liner with some grep-xargs-something-things-vi but I am starting to smell reinventing-the-wheel. [131003310120] |Sorry about the vim/emacs juxtaposition but I don't care which tool you use, use the most convenient (xargs/emacs/vi/m just examples). [131003320010] |M-xgrep in Emacs, then I can use the usual keys for following the links representing the found matches, and also the usual general-purpose Emacs keys for switching between buffers back and forth (or for whatever I want). [131003320020] |One can also learn the specialized keys for jumping to the next match. [131003320030] |The "specialized" key to jump immediately to the next found match is quite easy to remember: it's M-g n (go to next) (or C-x `) for next-error. next-error is a command that is more general-purpose than just for grep; from the help (per C-h k M-g n): [131003320040] |[It] normally uses the most recently started compilation, grep, or occur buffer. [131003320050] |(Indeed, first I learned it for LaTeX "compilation".) [131003320060] |More of the general "go to" commands bound to keys in my Emacs (as per M-g C-h): [131003330010] |Why did my crontab not trigger? [131003330020] |I used crontab -e to add the following line to my crontab: [131003330030] |Yet, I don't see that the test file is written to. [131003330040] |Is this a permission problem, or is crontab not working correctly? [131003330050] |I see that the cron process is running. [131003330060] |How can I debug this? [131003330070] |Edit - Ask Ubuntu has a nice question about crontab, unfortunately that still doesn't help me. [131003330080] |Edit 2 - Hmm, it seems my test file has 214 lines, which means for the last 214 minutes it has been written to every minute. [131003330090] |I'm not sure what was the problem, but it's evidently gone. [131003340010] |Your cron line works fine on my computer when I change myusernae to phunehehe. [131003340020] |There are several ways to find out what's wrong with your system. [131003340030] |Cron usually send mail to the user when there is something wrong. [131003340040] |If you see the message "You have mail" use a mail client to check your inbox. [131003340050] |Or, check in your home directory, there may be a file named dead.letter there. [131003340060] |You can check /var/log/ for entries relating to cron. [131003340070] |On my computer the log file is at /var/log/cron/current (requires root access). [131003340080] |If you have root access, you can stop the cron daemon and start it in debug mode. [131003340090] |For example I would use (change fcron to the name of your daemon): [131003350010] |Most likely, when cron fails, it generates an email to the user id of the cron job on that computer. [131003350020] |If you don't have an MTA working on your computer, or you aren't reading or forwarding that mail somewhere else, you won't see that message, even if the MTA is working. [131003350030] |A good way to get your crontab's errors via mail is to make your crontab look like this: [131003350040] |Obviously, use your email address rather than myemail@example.com. [131003350050] |This tells cron to send errors to your email address rather than the local account. [131003350060] |In particular, this is useful if you have a root crontab (or crontab fragment in /etc/cron.d) that you want to just send output to you, you can avoid spamming root's mailbox or root's forwarding address. [131003360010] |Have you added empty line after your cronjob? http://serverfault.com/q/230370/67116 [131003370010] |Sounds like this is fixed. [131003370020] |Next time, try logging the STDERR as well. [131003370030] |Instead of [131003370040] |Try to make sure there is an explicit location for STDERR. [131003370050] |Otherwise, STDERR may be sent via email to the user (assuming that email is working), or may go nowhere at all. [131003370060] |My preference is to send cronjob output to syslog. [131003370070] |That way I am taking advantage of any existing syslog infrastructure (centralized syslogs, Splunk, log rotation already supported, it's easy to compare messages in /var/log/messages &/var/log/cronjob, etc), and I'm not spamming the sysadmins (me) with unnecessary emails. [131003380010] |There are implementations of cron (not all of them, and I don't remember which offhand, but I've encountered one under Linux) that check for updated crontab files every minute on the minute, and do not consider new entries until the next minute. [131003380020] |Therefore, a crontab can take up to two minutes to fire up for the first time. [131003380030] |This may be what you observed. [131003390010] |How can I keep processes running on a remote server even after turning off the terminal machine? [131003390020] |..and then still be able to return to the same session/screen after restarting the terminal machine. [131003390030] |I've tried screen but once I restarted my computer screen -d showed no sessions. [131003390040] |Nohup seems to be what I want, but then I lose the ability to see the output later on, other than by saving it to a file. [131003390050] |Cannot I pretend more? [131003400010] |Screen should work fine. [131003400020] |Give more details about what you are doing. [131003400030] |Common commands: [131003400040] |I am not sure why you are using [131003400050] |All this does is detach a screen session, provided there is only one. [131003400060] |Otherwise it will ask which one you want to detach. [131003400070] |I also find [131003400080] |useful to show whether I am actually inside a screen or not, since this is not always obvious. [131003400090] |If in a screen, it will return screen. [131003400100] |If there are better ways to do this, I'd like to know about them. [131003410010] |I think that you were on the right way, screen is what you want and not nohup. [131003410020] |As you said with nohup you cannot change the settings get your environment back after logging out the remote server. screen supports that. [131003410030] |Look in this tutorial. [131003410040] |Basically what you need is: [131003410050] |Ctrl-a c [131003410060] |Ctrl-a d [131003420010] |What is the meaning of the number part of man pages? [131003420020] |Possible Duplicate: What do the numbers in a man page mean? [131003420030] |As in the "(1)" in git-svn(1) [131003430010] |Manpages are arranged into sections: [131003430020] |
  • General user commands
  • [131003430030] |
  • System calls
  • [131003430040] |
  • Standard library functions
  • [131003430050] |
  • Special files
  • [131003430060] |
  • File formats
  • [131003430070] |
  • Games
  • [131003430080] |
  • Conventions and operations
  • [131003430090] |
  • System administration commands
  • [131003430100] |
  • Kernel interfaces
  • [131003430110] |(These have changed around a bit over the years, and on some systems you may in particular notice sections 4 and 5 swapped.) [131003430120] |There may also be subsections, especially on System V-derived systems (3x, 3curses, etc.) [131003430130] |Some systems also have sections like l (local) and n (new). [131003430140] |Tcl/Tk manpages in particular like to install in section n, since many of them conflict with standard commands and functions. [131003440010] |Solaris 10 boot from cd-rom [131003440020] |I am trying to start up my solaris server using the newly downloaded iso written on a CD. [131003440030] |The iso name is sol-10-u9-ga-sparc-dvd.iso [131003440040] |When we started the server, logging in as root then tried to boot the system from CD-Rom, this is what happened: [131003440050] |After this, pressing Enter brings us a command prompt for sc>, but no boot command is recognized here. [131003440060] |How can we boot from the CD? [131003450010] |Can you give some more information? [131003450020] |If that is an Openboot, you can boot from cdrom with: [131003450030] |Anyway those ERROR messages doesn't look good.