Re: [Leaf-devel] How do I request help FAQ
On Tue, 12 Mar 2002, David Douthitt wrote: > On 3/12/02 at 6:56 AM, Jeff Newmiller <[EMAIL PROTECTED]> > wrote: > > > On Mon, 11 Mar 2002, David Douthitt wrote: > > > > Not really May I recommend: > > > > If you _are_ going to make a script, all sorts of options > > are available. As I said before, the problem is that it > > will have to be made easy to install... packaged, I guess. > > I would prefer to have it preinstalled into local.lrp (in > /usr/local/bin) or perhaps in usr.lrp (in /usr/sbin perhaps). If you are going to pre-install it as part of the distro, then you already know what diagnostics you need, and the whole "which" thing is pointless. > > > ( echo "Messages log\n" > > > > echo doesn't process escapes unless told to. > > At least one version I deal with daily doesn't need the -e option to > handle this. I suspect it was Linux, but I dunno. It requires the option on my system. If the portability of the "which" solution is needed, then the least common denominator must be adhered to. > > I prefer to be able to specify output destination. This > > may be undesirable from the point of view of teaching the > > uninitiated how to use it, but I think the trade is worth > > it. > > #!/bin/ksh /bin/ksh is not typically available. > OUTPUT=${1:-/tmp/debug_output.txt} > > ( > # snip > ) > $OUTPUT > > ...how about that? an interesting idea, but then I cannot use "more". > > Of course, you are stuck if your system doesn't have "which" :) > > Not quite: > > if type netstat > /dev/null 2>&1 ; then > > > ...works. Probably better, as type is an ash builtin and which is > included (or not) in busybox. That is clean. > > I have not really reviewed the set of diagnostics for > > completeness yet. For example, lsmod probably ought to be > > included. Perhaps "cat > > /etc/issue" ought to be included as well. > > /etc/issue includes ANSI escapes; are you SURE that would be a good > idea? Yeah, okay, but I am looking for some way to identify the flavor of the distro. If we could strip the ansi codes out somehow with sed... --- Jeff NewmillerThe . . Go Live... DCN:<[EMAIL PROTECTED]>Basics: ##.#. ##.#. Live Go... Live: OO#.. Dead: OO#.. Playing Research Engineer (Solar/BatteriesO.O#. #.O#. with /Software/Embedded Controllers) .OO#. .OO#. rocks...2k --- ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
On 3/12/02 at 9:15 AM, Charles Steinkuehler <[EMAIL PROTECTED]> wrote: > And a big disadvantage...it's a lot for someone to type > in, creating even more questions along the lines of "did > they type in the script correctly?". I was speaking from the standpoint of finally getting a script written and installed in a system - or in a package - not one to type in. There's been the barebones of a "script" (or set of diagnostics) to type in and people never seem to do it. > Create a diagnostic LRP package. This would have a script > similar to David's that dumps standard info to a file, > probably mounting the floppy and everything in the process > (we can have a fairly complex script, if folks arn't > typing it in by hand). Mounting a floppy and putting the data on it wouldn't be hard. I still prefer to build the script directly into the distribution, but a package would work. However, non-Oxygen distributions still require modification of syslinux.cfg or lrpkg.cfg before a package will load. > Create a diagnostic disk image. The idea here would be to > put everything needed onto a disk image (which presumably > even the greenest user can deal with, or they wouldn't be > having configuration problems :-). There would be a > fairly simple set of commands the user would run to mount > the disk and run the diagnostic script...everything else > would be automatic. I could see something like this: a user downloads the diagnostics disk image (and writes it to disk), boots with their own original boot image, then loads the disk by using a diagnostics selection from the main menu. The system automatically asks for the diagnostics image, and all packages are loaded (without any special configuration changes or adding packages). Then the data is gathered, stored on disk, and perhaps mailed (upon the user's confirmation). Oxygen has everything to do this already except an expanded package format to execute a script after loading the package... perhaps a startup script... -- David Douthitt UNIX Systems Administrator HP-UX, Unixware, Linux [EMAIL PROTECTED] ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
On 3/12/02 at 6:56 AM, Jeff Newmiller <[EMAIL PROTECTED]> wrote: > On Mon, 11 Mar 2002, David Douthitt wrote: > > Not really May I recommend: > > If you _are_ going to make a script, all sorts of options > are available. As I said before, the problem is that it > will have to be made easy to install... packaged, I guess. I would prefer to have it preinstalled into local.lrp (in /usr/local/bin) or perhaps in usr.lrp (in /usr/sbin perhaps). > > ( echo "Messages log\n" > > echo doesn't process escapes unless told to. At least one version I deal with daily doesn't need the -e option to handle this. I suspect it was Linux, but I dunno. > I prefer to be able to specify output destination. This > may be undesirable from the point of view of teaching the > uninitiated how to use it, but I think the trade is worth > it. #!/bin/ksh OUTPUT=${1:-/tmp/debug_output.txt} ( # snip ) > $OUTPUT ...how about that? > Of course, you are stuck if your system doesn't have "which" :) Not quite: if type netstat > /dev/null 2>&1 ; then ...works. Probably better, as type is an ash builtin and which is included (or not) in busybox. > I have not really reviewed the set of diagnostics for > completeness yet. For example, lsmod probably ought to be > included. Perhaps "cat > /etc/issue" ought to be included as well. /etc/issue includes ANSI escapes; are you SURE that would be a good idea? -- David Douthitt UNIX Systems Administrator HP-UX, Unixware, Linux [EMAIL PROTECTED] ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
On 3/12/02 at 7:31 AM, Ray Olszewski <[EMAIL PROTECTED]> wrote: > 1. Is incorporating a "diagnostics" script in into each > LEAF distribution a good idea? I think so. > But ... the FAQ mentions optional information, to be > supplied if circumstances warrant; how does one sensibly > incorporate that into a script? (Like all of us, I want > users to post enough information, but not too much.) #!/bin/sh echo -n "Do you wish to generate diagnostics for...? [Yn] " read X if [ "$X" = "y" -o "$X" = "Y" -o -z "$X" ] ; then gen_diagnostics... fi > 2. What should the FAQ tell users about collecting > troubleshooting data? Well, the discussion makes it clear > that a *standard* script that works across all LEAF > variants is either impractical or complicated (probably > just complicated). In any case, the FAQ itself can't > reasonably provide such a script. So I'd suggest the FAQ > retain the list of commands to use, and it can incorporate > references to scripts when they actually exist. But ... it > should always include the actual commands, because that is > part of the teaching role the FAQ can serve, helping the > user learn how to troubleshoot his or her own systems, not > *just* how to gather data for us to look at. I don't think a script would be that hard or that big; however, I agree wholeheartedly anyhow. -- David Douthitt UNIX Systems Administrator HP-UX, Unixware, Linux [EMAIL PROTECTED] ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
On Tue, 12 Mar 2002, Ray Olszewski wrote: > 1. Is incorporating a "diagnostics" script in into each LEAF distribution a > good idea? Probably (as long as it doesn't get so big as to cause problems > with fitting on a floppy). If we were going with a method that provides a separate disk image for diagnostics, this wouldn't be a problem. However, while the idea of a separate image is good, I don't think it's a way we want to go simply because it WILL confuse the users who need it most (at least, without reworking stuff so that it's a keypress or two to mount the new disk). > 2. What should the FAQ tell users about collecting troubleshooting data? > Well, the discussion makes it clear that a *standard* script that works > across all LEAF variants is either impractical or complicated (probably just > complicated). In any case, the FAQ itself can't reasonably provide such a > script. So I'd suggest the FAQ retain the list of commands to use, and it > can incorporate references to scripts when they actually exist. But ... it > should always include the actual commands, because that is part of the > teaching role the FAQ can serve, helping the user learn how to troubleshoot > his or her own systems, not *just* how to gather data for us to look at. I have to agree with this wholeheartedly. Not only do the various LEAF distros serve their intended purpose, but for more than one person (myself included) it also serves as an intro-to-Linux, giving a feel for how the basic system should work. If we DON'T leave those commands in there, then it will just frustrate the users who're trying to learn. (Yes, they could just open up the script, but I know *I* got dizzy the first time I looked at shell script) It sounds to me like the best solution would be to include links to scripts for those individuals who get dizzy around command lines somewhere after the list of commands to get the info manually. =) -- George Metz Commercial Routing Engineer [EMAIL PROTECTED] "We know what deterrence was with 'mutually assured destruction' during the Cold War. But what is deterrence in information warfare?" -- Brigadier General Douglas Richardson, USAF, Commander - Space Warfare Center ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
A quick comment: > 1. Is incorporating a "diagnostics" script in into each LEAF > distribution a good idea? Probably (as long as it doesn't get > so big as to cause problems with fitting on a floppy). This is a good idea. We could ask for users to post *at a minumum* the results of "~root/diagnose", which creates a file called "SENDME". That will provide a 90-percent solution, which sometimes is as good as you can get. -Scott ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
On Tue, 12 Mar 2002, Charles Steinkuehler wrote: [...] > Create a diagnostic disk image. The idea here would be to put everything > needed onto a disk image (which presumably even the greenest user can deal > with, or they wouldn't be having configuration problems :-). There would be > a fairly simple set of commands the user would run to mount the disk and run > the diagnostic script...everything else would be automatic. > > I see the disk image as perhaps the cleanest solution...it doesn't require > manual installation of LRP packages (or altering the bootup config to load a > new package), doesn't eat permanent ramdisk space, and the diagnostic disk > itself becomes the transport media for "sneaker net" migration of the output > to the primary workstation. > > Thoughts? Very nice! Might want to put a tool on the disk to allow the option of a CRLF version of the output file... perhaps even make nonCRLF output an option instead of the default. And/or compress output? --- Jeff NewmillerThe . . Go Live... DCN:<[EMAIL PROTECTED]>Basics: ##.#. ##.#. Live Go... Live: OO#.. Dead: OO#.. Playing Research Engineer (Solar/BatteriesO.O#. #.O#. with /Software/Embedded Controllers) .OO#. .OO#. rocks...2k --- ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
Having followed the discussion about the use of scripts to collect diagnostic information, I think we are muddling two distinct questions. 1. Is incorporating a "diagnostics" script in into each LEAF distribution a good idea? Probably (as long as it doesn't get so big as to cause problems with fitting on a floppy). And as soon as each variant's lead developer, or a helper, actually writes one that works for a particular LEAF variant, the FAQ should reference it. But ... the FAQ mentions optional information, to be supplied if circumstances warrant; how does one sensibly incorporate that into a script? (Like all of us, I want users to post enough information, but nort too much.) 2. What should the FAQ tell users about collecting troubleshooting data? Well, the discussion makes it clear that a *standard* script that works across all LEAF variants is either impractical or complicated (probably just complicated). In any case, the FAQ itself can't reasonably provide such a script. So I'd suggest the FAQ retain the list of commands to use, and it can incorporate references to scripts when they actually exist. But ... it should always include the actual commands, because that is part of the teaching role the FAQ can serve, helping the user learn how to troubleshoot his or her own systems, not *just* how to gather data for us to look at. At 06:56 AM 3/12/02 -0800, Jeff Newmiller wrote: >On Mon, 11 Mar 2002, David Douthitt wrote: [old stuff deleted] -- "Never tell me the odds!"--- Ray Olszewski-- Han Solo Palo Alto, CA[EMAIL PROTECTED] ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
> Not really May I recommend: > > ( echo "Messages log\n" > ) > /tmp/sysdata.txt > > This has several advantages: > > 1. Single file at the end for details - /tmp/sysdata.txt - just attach > and mail. If you use "matt" (new package to attach files to mail!) > you can even mail it right from the box. > > 2. Testing for existance of programs allows clean execution in even > the most spartan (or odd) environments. No ip? No problem. No > ipchains? No problem > > 3. Using a single file saves some space (constant redirections and > filenames). Of course, with all the testing (using which) the end > result is more bytes - but it's worth it, I think. And a big disadvantage...it's a lot for someone to type in, creating even more questions along the lines of "did they type in the script correctly?". I'd like to see a clean set of diagnostic information, but it's going to be hard to retrofit all the existing systems. Solutinons that come to mind: Create a diagnostic LRP package. This would have a script similar to David's that dumps standard info to a file, probably mounting the floppy and everything in the process (we can have a fairly complex script, if folks arn't typing it in by hand). Create a diagnostic disk image. The idea here would be to put everything needed onto a disk image (which presumably even the greenest user can deal with, or they wouldn't be having configuration problems :-). There would be a fairly simple set of commands the user would run to mount the disk and run the diagnostic script...everything else would be automatic. I see the disk image as perhaps the cleanest solution...it doesn't require manual installation of LRP packages (or altering the bootup config to load a new package), doesn't eat permanent ramdisk space, and the diagnostic disk itself becomes the transport media for "sneaker net" migration of the output to the primary workstation. Thoughts? Charles Steinkuehler http://lrp.steinkuehler.net http://c0wz.steinkuehler.net (lrp.c0wz.com mirror) ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
On Mon, 11 Mar 2002, David Douthitt wrote: > On 3/11/02 at 1:46 AM, Matt Schalit <[EMAIL PROTECTED]> wrote: > > > guitarlynn wrote: > > > The section below needs a little more work. The syntax shown > > will overwrite forward.txt. > > > > cp /var/log/messages /mnt/messages.txt > > ip addr show > /mnt/address.txt > > ipchains -nvL > /mnt/filter.txt > > /usr/sbin/ipmasqadm mfw -nL > /mnt/forward.txt > > /usr/sbin/ipmasqadm portfw -nl > /mnt/forward.txt > > cat /proc/net/ip_masq/autofw > /mnt/forward.txt > > > > And I request again that you add in > > > > ip route show > /mnt/routes.txt > > > > and remove the netstat -rn, only because ip route show > > is on every distro (correct?) > > Not really May I recommend: If you _are_ going to make a script, all sorts of options are available. As I said before, the problem is that it will have to be made easy to install... packaged, I guess. Not insurmountable, but I still like instructions that encourage people to examine their own diagnostics. > ( echo "Messages log\n" echo doesn't process escapes unless told to. > cat /var/log/messages > echo > > if which ip 2> /dev/null ; then >ip addr show >echo >ip route show > else >ifconfig -a >echo >netstat -rn > fi The idea of using tests to distinguish which set of diagnostic utilities to use is slick. I did notice that this fails to inform the reader which commands were in fact executed, and sequence can't really be relied on unless everyone agrees what it should be. [...] > > ) > /tmp/sysdata.txt See attached for further development of this concept... > This has several advantages: > > 1. Single file at the end for details - /tmp/sysdata.txt - just attach > and mail. If you use "matt" (new package to attach files to mail!) > you can even mail it right from the box. I prefer to be able to specify output destination. This may be undesirable from the point of view of teaching the uninitiated how to use it, but I think the trade is worth it. > 2. Testing for existance of programs allows clean execution in even > the most spartan (or odd) environments. No ip? No problem. No > ipchains? No problem Of course, you are stuck if your system doesn't have "which" :) > 3. Using a single file saves some space (constant redirections and > filenames). Of course, with all the testing (using which) the end > result is more bytes - but it's worth it, I think. But functions can reduce this a bit. Disclaimers: My modifications have been tested on a frankenstein 2.2.19 LRP 2.9.8. I have not really reviewed the set of diagnostics for completeness yet. For example, lsmod probably ought to be included. Perhaps "cat /etc/issue" ought to be included as well. Diagnostics from multiple participating machines are often needed to troubleshoot actual networking problems, and the choices encoded in a script like this one may have to be manually applied by the user to other operating systems before a meaningful solution can be found. --- Jeff NewmillerThe . . Go Live... DCN:<[EMAIL PROTECTED]>Basics: ##.#. ##.#. Live Go... Live: OO#.. Dead: OO#.. Playing Research Engineer (Solar/BatteriesO.O#. #.O#. with /Software/Embedded Controllers) .OO#. .OO#. rocks...2k --- #!/bin/sh # file : leafinfo # by : David Douthitt (DD) #Jeff Newmiller (JDN) myw() { unalias -a # unset may not work right for filenames beginning with "-", but # ash does not have the "--" option terminator. unset "$@" &> /dev/null # ash has no "enable" command... take chances with builtins # enable -n -- "$@" &> /dev/null # ash has no "-p" option for "type" builtin command type "$@" | sed "/not found/d;s/.*\( \)\([^ ]*\)$/\2/" } docmd() { echo "###BEGIN" echo "## \"$@\" ##" eval "$@" echo -e "###END##\n" } ( echo "## BEGIN REPORT ##" echo -e "Generated by: leafinfo v0.1\n" docmd "uname -a" docmd "cat /var/log/messages" if [ `myw ip` ]; then docmd "ip addr show" docmd "ip route show" else docmd "ifconfig -a" docmd "netstat -rn" fi if [ `myw ipchains` ]; then docmd "ipchains -L -v -n" else docmd "iptables -L -v -n" fi if [ `myw ipmasqadm` ]; then docmd "ipmasqadm mfw -L -n" docmd "ipmasqadm portfw -n -l" docmd "cat /proc/net/ip_masq/autofw" fi echo echo "## END REPORT ##" ) 2>&1
Re: [Leaf-devel] How do I request help FAQ
On 3/11/02 at 1:46 AM, Matt Schalit <[EMAIL PROTECTED]> wrote: > guitarlynn wrote: > The section below needs a little more work. The syntax shown > will overwrite forward.txt. > > cp /var/log/messages /mnt/messages.txt > ip addr show > /mnt/address.txt > ipchains -nvL > /mnt/filter.txt > /usr/sbin/ipmasqadm mfw -nL > /mnt/forward.txt > /usr/sbin/ipmasqadm portfw -nl > /mnt/forward.txt > cat /proc/net/ip_masq/autofw > /mnt/forward.txt > > > And I request again that you add in > > ip route show > /mnt/routes.txt > > and remove the netstat -rn, only because ip route show > is on every distro (correct?) Not really May I recommend: ( echo "Messages log\n" cat /var/log/messages echo if which ip 2> /dev/null ; then ip addr show echo ip route show else ifconfig -a echo netstat -rn fi echo if which ipchains 2> /dev/null ; then ipchains -L -v -n else iptables -L -v -n fi echo if which ipmasqadm 2> /dev/null ; then ipmasqadm mfw -L -n echo ipmasqadm portfw -n -l echo cat /proc/net/ip_masq/autofw echo fi ) > /tmp/sysdata.txt This has several advantages: 1. Single file at the end for details - /tmp/sysdata.txt - just attach and mail. If you use "matt" (new package to attach files to mail!) you can even mail it right from the box. 2. Testing for existance of programs allows clean execution in even the most spartan (or odd) environments. No ip? No problem. No ipchains? No problem 3. Using a single file saves some space (constant redirections and filenames). Of course, with all the testing (using which) the end result is more bytes - but it's worth it, I think. -- David Douthitt UNIX Systems Administrator HP-UX, Unixware, Linux [EMAIL PROTECTED] ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
On Monday 11 March 2002 03:46, Matt Schalit wrote: > The section below needs a little more work. The syntax shown > will overwrite forward.txt. It is fixed, thanks!!! > And I request again that you add in > > ip route show > /mnt/routes.txt > > and remove the netstat -rn, only because ip route show > is on every distro (correct?) It is as of last week. Fixed as well. Mike, could you add the new revision I added to the website. Thx! -- ~Lynn Avants aka Guitarlynn guitarlynn at users.sourceforge.net http://leaf.sourceforge.net If linux isn't the answer, you've probably got the wrong question! ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
Re: [Leaf-devel] How do I request help FAQ
guitarlynn wrote: > Alright, the "how do I ask for help" FAQ is posted > along with updates in all but 1 or 2 of the rest of > the FAQ's up to Section 7. You can check out the > new FAQ at: > > http://sourceforge.net/docman/display_doc.php?docid=1891&group_id=13751 > > Thanks to everyone for helping put it together!!! > The section below needs a little more work. The syntax shown will overwrite forward.txt. cp /var/log/messages /mnt/messages.txt ip addr show > /mnt/address.txt ipchains -nvL > /mnt/filter.txt /usr/sbin/ipmasqadm mfw -nL > /mnt/forward.txt /usr/sbin/ipmasqadm portfw -nl > /mnt/forward.txt cat /proc/net/ip_masq/autofw > /mnt/forward.txt And I request again that you add in ip route show > /mnt/routes.txt and remove the netstat -rn, only because ip route show is on every distro (correct?) Regards, Matthew ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel
[Leaf-devel] How do I request help FAQ
Alright, the "how do I ask for help" FAQ is posted along with updates in all but 1 or 2 of the rest of the FAQ's up to Section 7. You can check out the new FAQ at: http://sourceforge.net/docman/display_doc.php?docid=1891&group_id=13751 Thanks to everyone for helping put it together!!! -- ~Lynn Avants aka Guitarlynn guitarlynn at users.sourceforge.net http://leaf.sourceforge.net If linux isn't the answer, you've probably got the wrong question! ___ Leaf-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-devel