Date: Wed, 19 Dec 2012 09:16:20 +0200 From: Alexander Yerenkow <yerenkow@gmail.com> To: Edward <edward@rdtan.net> Cc: freebsd-doc@freebsd.org Subject: Re: [RFC] Q&A propose to add into FAQ Message-ID: <CAPJF9w=dUA0o93o8mrLreGnFiZaRaF6BgJqeOonc=r_OND0O0w@mail.gmail.com> In-Reply-To: <50D139D3.2010604@rdtan.net> References: <50CF471D.10407@rdtan.net> <CAF6rxgmeFnRifq0eyXzmFf7_YADOkMGYdOOVqwwS=D=n0GXr%2Bg@mail.gmail.com> <50D139D3.2010604@rdtan.net>
next in thread | previous in thread | raw e-mail | index | archive | help
Can I propose one item? When you have 100% filled zpool, you can't create file nor delete one. The only way to solve this situation is not obvious - you need to truncate (truncate -s 0 not-important-file or echo "" > not-important-file). I think this case should be mentioned in Q&A, if not already. 2012/12/19 Edward <edward@rdtan.net> > Hi Eitan, > > On 12/18/12 3:14 AM, Eitan Adler wrote: > > Lets focus on content and language first. The next step is turning > > this into docbook. I'll be happy to do that once we nail the > > language. > > > > I might write these like. I'm largely basing the content on what you > > wrote with some editorial changes. > > I'll answer your questions here and list the updated of the content > afterwards. > > > Q4: I just started a service, how do I figure out what TCP/UDP port it > > is listening on? > > A4: Use the utility "sockstat". Usage example, > > "sockstat -Ptcp" > > "sockstat -Pudp" > > > > ** maybe expand a bit more on this > > Done and it's updated at the bottom. > > > Q7: My server performance seems to be slow. How can I find out what > > the bottleneck is? > > A7: Use iostat(1). For example, "iostat -dw2" displays > > device (-d) statistic refreshing the output every 2 second (-w2). > > "iostat -Cw2" displaya CPU (-C) statistic. > > > > ** also mention sysstat here? > > Thanks for the tip and the utility systat is very useful tool to monitor > system states interactively. I've included some "unjust" mentions in it > (A7) but avoided a too lengthy introduction. As I thought Q&A should not > be too long to read. But please do correct me if I'm wrong. > > > Q8: FreeBSD seems to be rejecting connections because > > of too many TCP connections in the "TIME_WAIT" state. > > How can I reduce the timeout? > > > > ** I can't comment on the answer specifics here. Seems okay though > > can do with a bit of English editing > > I've done some cosmetic changes to the answer (A8) and wait for any > advise & changes needed. > > > Q9: I just changed /etc/newsyslog.conf. How can I check if it does > > what I expect? > > ... > > Done and it's updated at the bottom. > > > Q10: The output of "ps" is truncated to the end of my terminal width and > > I can't see the program name. > > > > ** I'm not sure I'd make this an FAQ. Is this commonly asked? > > I thought it would be helpful because most of the admins around me seems > to be bother by this and opt to adjust the terminal width big enough to > accommodate "ps" output. But rather, "ps" output can be set to disregard > the terminal width. But then, I'm fine if this is excluded :) > > >> By the way, do you guys think is there any chance that this Q&A can > >> squeeze into the FAQ? > > > > I have no objections... > > > > I'll update the sequence of the Q&A number 10 by replacing it with this. > > Here's the updated version : > > Q1: Boot messages are missing from dmesg. Where can I find them? > A1: Kernel log messages are recorded in /var/log/messages, > /var/log/dmesg.yesterday, and /var/log/dmesg.today. Boot time > messages are recorded in /var/run/dmesg.boot. > > Q2: I have some software which only works on very old versions of > FreeBSD, where can I get these? > A2: Older versions of FreeBSD can be obtained from > ftp://ftp-archive.freebsd.org/pub/FreeBSD-Archive/old-releases/. > Most of these versions are past End of Life and > can be extremely buggy or insecure, use at your own risk. > > Q3: I have a piece of software that runs only on 64 bit processor. How > do I know my current processor is capable of 64 bit processing? > A3: Look at /var/run/dmesg.boot, search for the line with "AMD > Features". If CPU features flag "LM" is present, the processor > supports 64 bit processing. Otherwise, it is likely to be a 32 bit > processor. > > Here is an example of a 64 bit processor: > AMD Features=0x28100000<NX,RDTSCP,LM> > > Q4: I just started a service, how do I figure out what TCP/UDP port it > is listening on? > A4: Use the utility "sockstat" to list open/listening ports. Here is an > example of listing TCP ports "sockstat -Ptcp". To list UDP ports > instead, execute "sockstat -Pudp". > > Q5: My time is wrong, how can I change the timezone? > A5: Use "tzsetup" utility. > > Q6: I'm troubleshooting a network link issue, how can I generate big > size file to test network transfer speed? > A6: Use the utility "dd". For example, "dd if=/dev/random > of=hugefile.txt bs=1m count=1k" would create a file called hugefile.txt > with the size of 1GB. > > Q7: My server performance seems to be slow. How can I find out what > the bottleneck is? > A7: Use iostat(1). For example, "iostat -dw2" displays device (-d) > statistic refreshing the output every 2 second (-w2). "iostat -Cw2" > displaya CPU (-C) statistic. > Also, "systat" is another interactive tool to monitor system statistics. > Its operation are similar to "vim" behavior. Check out "systat" man page > for more info. > > Q8: FreeBSD seems to be rejecting connections because of too many TCP > connections in the "TIME_WAIT" state. How can I reduce the timeout? > A8: In short, tune the sysctl value "net.inet.tcp.msl" to something > modern and acceptable, such as 7500. > In detail, the default timeout value for TIME_WAIT status is set to 60 > seconds. This value is based on RFC 793. Since this RFC is drafted in > year 1981, equipments and bandwidth of that time was not as fast as what > we have now. A 60 seconds of waiting for TCP session to terminate, is a > long time. For a busy server opening and closing TCP connections, this > value should set to a shorter time, such as 15 seconds. > The value of "net.inet.tcp.msl" is not the usual "literal" seconds > though. In order to reduce from the default 60 seconds to 15 seconds, > firstly, convert it to milliseconds. Then divide it by 2. > For example, when 15 seconds is converted to 15,000 milliseconds, it > then should be divided by 2, which sums up to "7500". This will be the > value for "net.inet.tcp.msl", which equivalent to 15 seconds. > > Q9: I just changed /etc/newsyslog.conf. How can I check if it does what > I expect? > A9: Use the parameter "-nvv" when executing "newsyslog". For example, > "newsyslog -nvv" would tell what are each of the lines in > /etc/newsyslog.conf would do when the time comes. > > Q10: My this colleague/friend sits at the computer too much, how > can I punk her? > A10: Install "games/sl" and then wait for her to mistype "sl" for "ls". > > Your comments is much appreciated and glad to get more :) > > Regards, > Edward. > _______________________________________________ > freebsd-doc@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-doc > To unsubscribe, send any mail to "freebsd-doc-unsubscribe@freebsd.org" > -- Regards, Alexander Yerenkow
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAPJF9w=dUA0o93o8mrLreGnFiZaRaF6BgJqeOonc=r_OND0O0w>