From owner-freebsd-geom@FreeBSD.ORG Mon Mar 15 06:23:14 2010 Return-Path: Delivered-To: freebsd-geom@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 61420106564A; Mon, 15 Mar 2010 06:23:14 +0000 (UTC) (envelope-from linimon@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 3807F8FC1E; Mon, 15 Mar 2010 06:23:14 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id o2F6NElM056115; Mon, 15 Mar 2010 06:23:14 GMT (envelope-from linimon@freefall.freebsd.org) Received: (from linimon@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id o2F6NEqN056111; Mon, 15 Mar 2010 06:23:14 GMT (envelope-from linimon) Date: Mon, 15 Mar 2010 06:23:14 GMT Message-Id: <201003150623.o2F6NEqN056111@freefall.freebsd.org> To: linimon@FreeBSD.org, freebsd-bugs@FreeBSD.org, freebsd-geom@FreeBSD.org From: linimon@FreeBSD.org Cc: Subject: Re: kern/144732: [geom] [patch] geom_cache erroneously decodes its on-disk label X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Mar 2010 06:23:14 -0000 Old Synopsis: [patch] geom_cache erroneously decodes its on-disk label New Synopsis: [geom] [patch] geom_cache erroneously decodes its on-disk label Responsible-Changed-From-To: freebsd-bugs->freebsd-geom Responsible-Changed-By: linimon Responsible-Changed-When: Mon Mar 15 06:23:00 UTC 2010 Responsible-Changed-Why: Over to maintainer(s). http://www.freebsd.org/cgi/query-pr.cgi?pr=144732 From owner-freebsd-geom@FreeBSD.ORG Mon Mar 15 10:52:48 2010 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2DB571065670; Mon, 15 Mar 2010 10:52:48 +0000 (UTC) (envelope-from pjd@garage.freebsd.pl) Received: from mail.garage.freebsd.pl (chello089077043238.chello.pl [89.77.43.238]) by mx1.freebsd.org (Postfix) with ESMTP id 5E2D68FC24; Mon, 15 Mar 2010 10:52:46 +0000 (UTC) Received: by mail.garage.freebsd.pl (Postfix, from userid 65534) id DC22945EC0; Mon, 15 Mar 2010 11:52:41 +0100 (CET) Received: from localhost (pdawidek.wheel.pl [10.0.1.1]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.garage.freebsd.pl (Postfix) with ESMTP id ED6FD45DD8; Mon, 15 Mar 2010 11:52:37 +0100 (CET) Date: Mon, 15 Mar 2010 11:52:38 +0100 From: Pawel Jakub Dawidek To: Jaakko Heinonen Message-ID: <20100315105238.GB3103@garage.freebsd.pl> References: <20100313083551.GB966@a91-153-117-195.elisa-laajakaista.fi> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="BwCQnh7xodEAoBMC" Content-Disposition: inline In-Reply-To: <20100313083551.GB966@a91-153-117-195.elisa-laajakaista.fi> User-Agent: Mutt/1.4.2.3i X-PGP-Key-URL: http://people.freebsd.org/~pjd/pjd.asc X-OS: FreeBSD 9.0-CURRENT i386 X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on mail.garage.freebsd.pl X-Spam-Level: X-Spam-Status: No, score=-5.9 required=4.5 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.0.4 Cc: phk@FreeBSD.org, freebsd-geom@FreeBSD.org Subject: Re: Escape unsafe characters for kern.geom.confxml XML dump X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Mar 2010 10:52:48 -0000 --BwCQnh7xodEAoBMC Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Mar 13, 2010 at 10:35:52AM +0200, Jaakko Heinonen wrote: >=20 > Hi, >=20 > I intend to commit following patch unless there are objections. I have > seen the problem commonly reported by FreeBSD users. >=20 > --- >=20 > Escape characters unsafe for XML output in GEOM class, instance and provi= der > names. >=20 > - Characters in range 0x01-0x1f except '\t', '\n', and '\r' are replaced > with '?'. Those characters are disallowed in XML. > - '&', '<', '>', '\'', '"' and characters in range 0x7f-0xff are replaced > with XML numeric character reference. >=20 > If the kern.geom.confxml sysctl provides invalid XML, libgeom > geom_xml2tree() fails and utilities using it do not work. Unsafe > characters are common in msdosfs and cd9660 labels. >=20 > PR: kern/104389 > Submitter by: Doug Steinwand (original version) Patch looks good and it was something missing for a very long time. Thanks for taking care of this. --=20 Pawel Jakub Dawidek http://www.wheelsystems.com pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --BwCQnh7xodEAoBMC Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (FreeBSD) iEYEARECAAYFAkueEXYACgkQForvXbEpPzSSaQCfeAQqgpMMJgAzkcp6A26L1/hC QBgAoKxG6UlrBrpnGYQB8snl5mAxaVtI =qDvd -----END PGP SIGNATURE----- --BwCQnh7xodEAoBMC-- From owner-freebsd-geom@FreeBSD.ORG Mon Mar 15 11:07:13 2010 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 201091065675 for ; Mon, 15 Mar 2010 11:07:13 +0000 (UTC) (envelope-from owner-bugmaster@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id E82DF8FC20 for ; Mon, 15 Mar 2010 11:07:12 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id o2FB7CJo026871 for ; Mon, 15 Mar 2010 11:07:12 GMT (envelope-from owner-bugmaster@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id o2FB7CLv026868 for freebsd-geom@FreeBSD.org; Mon, 15 Mar 2010 11:07:12 GMT (envelope-from owner-bugmaster@FreeBSD.org) Date: Mon, 15 Mar 2010 11:07:12 GMT Message-Id: <201003151107.o2FB7CLv026868@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: gnats set sender to owner-bugmaster@FreeBSD.org using -f From: FreeBSD bugmaster To: freebsd-geom@FreeBSD.org Cc: Subject: Current problem reports assigned to freebsd-geom@FreeBSD.org X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Mar 2010 11:07:13 -0000 Note: to view an individual PR, use: http://www.freebsd.org/cgi/query-pr.cgi?pr=(number). The following is a listing of current problems submitted by FreeBSD users. These represent problem reports covering all versions including experimental development code and obsolete releases. S Tracker Resp. Description -------------------------------------------------------------------------------- o kern/144732 geom [geom] [patch] geom_cache erroneously decodes its on-d o bin/144521 geom geom(1) tool parsing non-subclass command broken o kern/143455 geom gstripe(8) in RELENG_8 (31st Jan 2010) broken o kern/142563 geom [geom] [hang] ioctl freeze in zpool f kern/142365 geom [geom] FreeBSD RAID1 (gmirror) is much slower than Lin o kern/141740 geom [geom] gjournal(8): g_journal_destroy concurrent error o kern/140352 geom [geom] gjournal + glabel not working o kern/139847 geom [geom_mbr] [patch] load/unload causes system to hang o kern/135898 geom [geom] Severe filesystem corruption - large files or l o kern/134922 geom [gmirror] [panic] kernel panic when use fdisk on disk o kern/134113 geom [geli] Problem setting secondary GELI key o kern/134044 geom [geom] gmirror(8) overwrites fs with stale data from r o kern/133931 geom [geli] [request] intentionally wrong password to destr o bin/132845 geom [geom] [patch] ggated(8) does not close files opened a o kern/132273 geom glabel(8): [patch] failing on journaled partition f kern/132242 geom [gmirror] gmirror.ko fails to fully initialize o kern/131353 geom [geom] gjournal(8) kernel lock p docs/130548 geom [patch] gjournal(8) man page is missing sysctls o kern/129674 geom [geom] gjournal root did not mount on boot o kern/129645 geom gjournal(8): GEOM_JOURNAL causes system to fail to boo o kern/129245 geom [geom] gcache is more suitable for suffix based provid f kern/128276 geom [gmirror] machine lock up when gmirror module is used f kern/126902 geom [geom] geom_label: kernel panic during install boot o kern/124973 geom [gjournal] [patch] boot order affects geom_journal con o kern/124969 geom gvinum(8): gvinum raid5 plex does not detect missing s o kern/123962 geom [panic] [gjournal] gjournal (455Gb data, 8Gb journal), o kern/123122 geom [geom] GEOM / gjournal kernel lock o kern/122738 geom [geom] gmirror list "losts consumers" after gmirror de f kern/122415 geom [geom] UFS labels are being constantly created and rem o kern/122067 geom [geom] [panic] Geom crashed during boot o kern/121559 geom [patch] [geom] geom label class allows to create inacc o kern/121364 geom [gmirror] Removing all providers create a "zombie" mir o kern/120091 geom [geom] [geli] [gjournal] geli does not prompt for pass o kern/119743 geom [geom] geom label for cds is keeped after dismount and o kern/115856 geom [geli] ZFS thought it was degraded when it should have o kern/115547 geom [geom] [patch] [request] let GEOM Eli get password fro o kern/114532 geom [geom] GEOM_MIRROR shows up in kldstat even if compile f kern/113957 geom [gmirror] gmirror is intermittently reporting a degrad o kern/113837 geom [geom] unable to access 1024 sector size storage o kern/113419 geom [geom] geom fox multipathing not failing back p bin/110705 geom gmirror(8) control utility does not exit with correct o kern/107707 geom [geom] [patch] [request] add new class geom_xbox360 to o kern/104389 geom [geom] [patch] sys/geom/geom_dump.c doesn't encode XML o kern/94632 geom [geom] Kernel output resets input while GELI asks for o kern/90582 geom [geom] [panic] Restore cause panic string (ffs_blkfree o bin/90093 geom fdisk(8) incapable of altering in-core geometry o kern/88601 geom [geli] geli cause kernel panic under heavy disk usage o kern/87544 geom [gbde] mmaping large files on a gbde filesystem deadlo o kern/84556 geom [geom] [panic] GBDE-encrypted swap causes panic at shu o kern/79251 geom [2TB] newfs fails on 2.6TB gbde device o kern/79035 geom [vinum] gvinum unable to create a striped set of mirro o bin/78131 geom gbde(8) "destroy" not working. s kern/73177 geom kldload geom_* causes panic due to memory exhaustion 53 problems total. From owner-freebsd-geom@FreeBSD.ORG Mon Mar 15 19:51:04 2010 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 72FCA106564A; Mon, 15 Mar 2010 19:51:04 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from gw01.mail.saunalahti.fi (gw01.mail.saunalahti.fi [195.197.172.115]) by mx1.freebsd.org (Postfix) with ESMTP id 384C78FC0A; Mon, 15 Mar 2010 19:51:03 +0000 (UTC) Received: from a91-153-117-195.elisa-laajakaista.fi (a91-153-117-195.elisa-laajakaista.fi [91.153.117.195]) by gw01.mail.saunalahti.fi (Postfix) with SMTP id A4FEC151777; Mon, 15 Mar 2010 21:51:00 +0200 (EET) Date: Mon, 15 Mar 2010 21:51:00 +0200 From: Jaakko Heinonen To: freebsd-geom@FreeBSD.org, pjd@FreeBSD.org Message-ID: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-06-14) Cc: Subject: geom_label and directories under /dev X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Mar 2010 19:51:04 -0000 Hi, I was working to fix problems with GEOM label class allowing some problematic label names which can't represent proper files under /dev. For example: - empty label - "." and ".." - labels starting or ending with '/' - labels ending with /.. (Due to a bug for example /..foo/.. is allowed.) Then I noticed that directories are also problematic. Here's how to panic your system: # glabel create ab ad0 # glabel create ab/cd ad0 # ls -l /dev/label I was going to suggest disallowing of '/' in labels but in past such change has been reverted. ------------------------------------------------------------------------ r149339 | pjd | 2005-08-20 20:05:47 +0300 (Sat, 20 Aug 2005) | 5 lines Back-out the change from revision 1.14 and allow for '/' in labels again. Convinced by: green, Gavin Atkinson, dougb, gordon MFC after: 1 day ------------------------------------------------------------------------ So it's probably a dead end to try to suggest disallowing of '/'? Unfortunately it's not easy to fix all problems with directories. For starters devfs doesn't support removal of directories at all. Opinions? -- Jaakko From owner-freebsd-geom@FreeBSD.ORG Mon Mar 15 20:43:23 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 488D3106566B for ; Mon, 15 Mar 2010 20:43:23 +0000 (UTC) (envelope-from gcubfg-freebsd-geom@m.gmane.org) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by mx1.freebsd.org (Postfix) with ESMTP id 03A5A8FC0C for ; Mon, 15 Mar 2010 20:43:22 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1NrH8C-0007Mq-Iu for freebsd-geom@freebsd.org; Mon, 15 Mar 2010 21:43:20 +0100 Received: from 93-138-83-214.adsl.net.t-com.hr ([93.138.83.214]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 15 Mar 2010 21:43:20 +0100 Received: from ivoras by 93-138-83-214.adsl.net.t-com.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 15 Mar 2010 21:43:20 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-geom@freebsd.org From: Ivan Voras Date: Mon, 15 Mar 2010 21:43:07 +0100 Lines: 44 Message-ID: References: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: 93-138-83-214.adsl.net.t-com.hr User-Agent: Thunderbird 2.0.0.21 (X11/20090612) In-Reply-To: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> Subject: Re: geom_label and directories under /dev X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Mar 2010 20:43:23 -0000 Jaakko Heinonen wrote: > Hi, > > I was working to fix problems with GEOM label class allowing some > problematic label names which can't represent proper files under /dev. > For example: > > - empty label > - "." and ".." > - labels starting or ending with '/' > - labels ending with /.. (Due to a bug for example /..foo/.. is > allowed.) Also, encoding needs to be adjusted in some cases (e.g. NTFS, FAT32?). The only sane choices are 7-bit ASCII or UTF-8. Also, kern.geom.confxml needs to escape or strip XML-special characters... > Then I noticed that directories are also problematic. Here's how to > panic your system: > > # glabel create ab ad0 > # glabel create ab/cd ad0 > # ls -l /dev/label > > I was going to suggest disallowing of '/' in labels but in past such > change has been reverted. > > ------------------------------------------------------------------------ > r149339 | pjd | 2005-08-20 20:05:47 +0300 (Sat, 20 Aug 2005) | 5 lines > > Back-out the change from revision 1.14 and allow for '/' in labels > again. > > Convinced by: green, Gavin Atkinson, dougb, gordon > MFC after: 1 day > > ------------------------------------------------------------------------ > > So it's probably a dead end to try to suggest disallowing of '/'? > Unfortunately it's not easy to fix all problems with directories. For > starters devfs doesn't support removal of directories at all. I have no idea why "/" would be allowed - it isn't in regular filenames so why would this be special? I wote to remove slashes. From owner-freebsd-geom@FreeBSD.ORG Mon Mar 15 20:49:26 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DCD321065672 for ; Mon, 15 Mar 2010 20:49:26 +0000 (UTC) (envelope-from gcubfg-freebsd-geom@m.gmane.org) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by mx1.freebsd.org (Postfix) with ESMTP id 975F98FC1B for ; Mon, 15 Mar 2010 20:49:26 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1NrHE5-0001HS-Kl for freebsd-geom@freebsd.org; Mon, 15 Mar 2010 21:49:25 +0100 Received: from 93-138-83-214.adsl.net.t-com.hr ([93.138.83.214]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 15 Mar 2010 21:49:25 +0100 Received: from ivoras by 93-138-83-214.adsl.net.t-com.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 15 Mar 2010 21:49:25 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-geom@freebsd.org From: Ivan Voras Date: Mon, 15 Mar 2010 21:49:15 +0100 Lines: 26 Message-ID: References: <20100313083551.GB966@a91-153-117-195.elisa-laajakaista.fi> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: 93-138-83-214.adsl.net.t-com.hr User-Agent: Thunderbird 2.0.0.21 (X11/20090612) In-Reply-To: <20100313083551.GB966@a91-153-117-195.elisa-laajakaista.fi> Subject: Re: Escape unsafe characters for kern.geom.confxml XML dump X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Mar 2010 20:49:26 -0000 Jaakko Heinonen wrote: > Hi, > > I intend to commit following patch unless there are objections. I have > seen the problem commonly reported by FreeBSD users. > > --- > > Escape characters unsafe for XML output in GEOM class, instance and provider > names. Go for it! > + for (c = str; *c != '\0'; c++) { > + if (*c == '&' || *c == '<' || *c == '>' || > + *c == '\'' || *c == '"' || *c > 0x7e) > + sbuf_printf(s, "&#x%X;", *c); > + else if (*c == '\t' || *c == '\n' || *c == '\r' || *c > 0x1f) > + sbuf_putc(s, *c); > + else > + sbuf_putc(s, '?'); Wouldn't it be slightly better (it's not important, really), to use HTML "entities" instead - & > < ' " ? The only benefit (which is why it isn't important) is that it would make it more human-readable. From owner-freebsd-geom@FreeBSD.ORG Mon Mar 15 23:30:35 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3336A106566B for ; Mon, 15 Mar 2010 23:30:35 +0000 (UTC) (envelope-from cyberleo@cyberleo.net) Received: from paka.cyberleo.net (paka.cyberleo.net [66.219.31.21]) by mx1.freebsd.org (Postfix) with ESMTP id 0CAE08FC0C for ; Mon, 15 Mar 2010 23:30:34 +0000 (UTC) Received: from [172.16.44.14] (h-74-2-96-2.chcgilgm.static.covad.net [74.2.96.2]) by paka.cyberleo.net (Postfix) with ESMTPSA id 09C6C295B9; Mon, 15 Mar 2010 19:12:40 -0400 (EDT) Message-ID: <4B9EBEE7.5080803@cyberleo.net> Date: Mon, 15 Mar 2010 18:12:39 -0500 From: CyberLeo Kitsana User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.8) Gecko/20100307 Thunderbird/3.0.3 MIME-Version: 1.0 To: Ivan Voras References: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> In-Reply-To: X-Enigmail-Version: 1.0.1 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-geom@freebsd.org Subject: Re: geom_label and directories under /dev X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Mar 2010 23:30:35 -0000 On 03/15/2010 03:43 PM, Ivan Voras wrote: > Jaakko Heinonen wrote: >> So it's probably a dead end to try to suggest disallowing of '/'? >> Unfortunately it's not easy to fix all problems with directories. For >> starters devfs doesn't support removal of directories at all. > > I have no idea why "/" would be allowed - it isn't in regular filenames > so why would this be special? I wote to remove slashes. Please be very careful with such a change. I rely on this behaviour pretty heavily, to keep things hierarchically arranged. Such a change would break pretty much every box I run. -- Fuzzy love, -CyberLeo Technical Administrator CyberLeo.Net Webhosting http://www.CyberLeo.Net Furry Peace! - http://wwww.fur.com/peace/ From owner-freebsd-geom@FreeBSD.ORG Mon Mar 15 23:35:01 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BA58E106566C for ; Mon, 15 Mar 2010 23:35:01 +0000 (UTC) (envelope-from ivoras@gmail.com) Received: from mail-ww0-f54.google.com (mail-ww0-f54.google.com [74.125.82.54]) by mx1.freebsd.org (Postfix) with ESMTP id AE1028FC22 for ; Mon, 15 Mar 2010 23:35:00 +0000 (UTC) Received: by wwb18 with SMTP id 18so483948wwb.13 for ; Mon, 15 Mar 2010 16:34:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:in-reply-to :references:from:date:x-google-sender-auth:message-id:subject:to:cc :content-type; bh=ApcPS9nuc3fyx7MHLZA9oaP7gko5KCvtrS2ze4WQL+U=; b=Bhc2MjXIB2Mwu++gH8d3cfpzgdUQmr1EzFrwPW5TYm0Bln/63qMer20DUkyb2OPlVT poNhseICyWUJKPzI7XqTG7j5dXnGSIU96kiOriCGvYQVKoEKXUqWkl33NfP2kfQIToHK cxLclkpqOnMFmiXYLkHEAEAu8D6dqu4aQbdCk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; b=Qfptf0OlPLfy4FA+xmnl7BOynjIHrlHg1cf9YBynVTRAYCYNqcMTUUGB7sHpBRuOKS VjSb7Ld6U3L+zKH1SwV9QM6SLfWvvMoZWf29TpyWU51emkS54xIW4q0FsgAUMJESvgdS lFOreJ/mD5EPOZr6Y0KuVP38sRidITqttcpS4= MIME-Version: 1.0 Sender: ivoras@gmail.com Received: by 10.216.157.134 with SMTP id o6mr8320wek.58.1268696099494; Mon, 15 Mar 2010 16:34:59 -0700 (PDT) In-Reply-To: <4B9EBEE7.5080803@cyberleo.net> References: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> <4B9EBEE7.5080803@cyberleo.net> From: Ivan Voras Date: Tue, 16 Mar 2010 00:34:39 +0100 X-Google-Sender-Auth: 4b21f94cb4181aa7 Message-ID: <9bbcef731003151634r56fa1a81v74def629ca97e506@mail.gmail.com> To: CyberLeo Kitsana Content-Type: text/plain; charset=UTF-8 Cc: freebsd-geom@freebsd.org Subject: Re: geom_label and directories under /dev X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Mar 2010 23:35:01 -0000 On 16 March 2010 00:12, CyberLeo Kitsana wrote: > On 03/15/2010 03:43 PM, Ivan Voras wrote: >> Jaakko Heinonen wrote: >>> So it's probably a dead end to try to suggest disallowing of '/'? >>> Unfortunately it's not easy to fix all problems with directories. For >>> starters devfs doesn't support removal of directories at all. >> >> I have no idea why "/" would be allowed - it isn't in regular filenames >> so why would this be special? I wote to remove slashes. > > Please be very careful with such a change. I rely on this behaviour > pretty heavily, to keep things hierarchically arranged. Such a change > would break pretty much every box I run. I see your point about not breaking your setup but - would you expect normal file systems to host files with slashes in their filenames? It works in GEOM+devfs mostly by accident - I'm sure you would agree that it is definitely something unexpected - a bug, even, and relying on such unexpected behaviour should not suddenly become official policy. It would make life difficult if there is ever something else that also needs to parse labels and assign them to devices, and besides that it's generally ugly. From owner-freebsd-geom@FreeBSD.ORG Mon Mar 15 23:52:03 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6135A106566B for ; Mon, 15 Mar 2010 23:52:03 +0000 (UTC) (envelope-from pjd@garage.freebsd.pl) Received: from mail.garage.freebsd.pl (chello089077043238.chello.pl [89.77.43.238]) by mx1.freebsd.org (Postfix) with ESMTP id A596F8FC15 for ; Mon, 15 Mar 2010 23:52:02 +0000 (UTC) Received: by mail.garage.freebsd.pl (Postfix, from userid 65534) id 5B47D45CBA; Tue, 16 Mar 2010 00:52:00 +0100 (CET) Received: from localhost (chello089077043238.chello.pl [89.77.43.238]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.garage.freebsd.pl (Postfix) with ESMTP id 2E88145C8C; Tue, 16 Mar 2010 00:51:55 +0100 (CET) Date: Tue, 16 Mar 2010 00:51:55 +0100 From: Pawel Jakub Dawidek To: CyberLeo Kitsana Message-ID: <20100315235155.GA3574@garage.freebsd.pl> References: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> <4B9EBEE7.5080803@cyberleo.net> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="a8Wt8u1KmwUX3Y2C" Content-Disposition: inline In-Reply-To: <4B9EBEE7.5080803@cyberleo.net> User-Agent: Mutt/1.4.2.3i X-PGP-Key-URL: http://people.freebsd.org/~pjd/pjd.asc X-OS: FreeBSD 9.0-CURRENT i386 X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on mail.garage.freebsd.pl X-Spam-Level: X-Spam-Status: No, score=-0.6 required=4.5 tests=BAYES_00,RCVD_IN_SORBS_DUL autolearn=no version=3.0.4 Cc: freebsd-geom@freebsd.org Subject: Re: geom_label and directories under /dev X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Mar 2010 23:52:03 -0000 --a8Wt8u1KmwUX3Y2C Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Mar 15, 2010 at 06:12:39PM -0500, CyberLeo Kitsana wrote: > On 03/15/2010 03:43 PM, Ivan Voras wrote: > > Jaakko Heinonen wrote: > >> So it's probably a dead end to try to suggest disallowing of '/'? > >> Unfortunately it's not easy to fix all problems with directories. For > >> starters devfs doesn't support removal of directories at all. > >=20 > > I have no idea why "/" would be allowed - it isn't in regular filenames > > so why would this be special? I wote to remove slashes. >=20 > Please be very careful with such a change. I rely on this behaviour > pretty heavily, to keep things hierarchically arranged. Such a change > would break pretty much every box I run. No worries. I agree it is useful. File system labels are not file names and I'm happy that our devfs support transparent directory creation, because thanks to this we can use directory names in labels for free. There sure are devfs bugs that have to be fixed and not avoided by limiting flexibility in GEOM providers names selection. --=20 Pawel Jakub Dawidek http://www.wheelsystems.com pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --a8Wt8u1KmwUX3Y2C Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (FreeBSD) iEYEARECAAYFAkueyBsACgkQForvXbEpPzSVNwCg0AlP/mAylsa3bk3A3S4g7csP gaUAni3NHJFTyVopxAp/Fk1RMbPcDs0D =t3aP -----END PGP SIGNATURE----- --a8Wt8u1KmwUX3Y2C-- From owner-freebsd-geom@FreeBSD.ORG Tue Mar 16 00:01:40 2010 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C4D981065672; Tue, 16 Mar 2010 00:01:40 +0000 (UTC) (envelope-from pjd@garage.freebsd.pl) Received: from mail.garage.freebsd.pl (chello089077043238.chello.pl [89.77.43.238]) by mx1.freebsd.org (Postfix) with ESMTP id 148D38FC13; Tue, 16 Mar 2010 00:01:39 +0000 (UTC) Received: by mail.garage.freebsd.pl (Postfix, from userid 65534) id B446B45E90; Tue, 16 Mar 2010 01:01:38 +0100 (CET) Received: from localhost (chello089077043238.chello.pl [89.77.43.238]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.garage.freebsd.pl (Postfix) with ESMTP id 537AA45CA6; Tue, 16 Mar 2010 01:01:33 +0100 (CET) Date: Tue, 16 Mar 2010 01:01:33 +0100 From: Pawel Jakub Dawidek To: Jaakko Heinonen Message-ID: <20100316000133.GC3574@garage.freebsd.pl> References: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="ncSAzJYg3Aa9+CRW" Content-Disposition: inline In-Reply-To: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> User-Agent: Mutt/1.4.2.3i X-PGP-Key-URL: http://people.freebsd.org/~pjd/pjd.asc X-OS: FreeBSD 9.0-CURRENT i386 X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on mail.garage.freebsd.pl X-Spam-Level: X-Spam-Status: No, score=-0.6 required=4.5 tests=BAYES_00,RCVD_IN_SORBS_DUL autolearn=no version=3.0.4 Cc: freebsd-geom@FreeBSD.org Subject: Re: geom_label and directories under /dev X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Mar 2010 00:01:40 -0000 --ncSAzJYg3Aa9+CRW Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Mar 15, 2010 at 09:51:00PM +0200, Jaakko Heinonen wrote: >=20 > Hi, >=20 > I was working to fix problems with GEOM label class allowing some > problematic label names which can't represent proper files under /dev. > For example: >=20 > - empty label > - "." and ".." > - labels starting or ending with '/' > - labels ending with /.. (Due to a bug for example /..foo/.. is > allowed.) >=20 > Then I noticed that directories are also problematic. Here's how to > panic your system: >=20 > # glabel create ab ad0 > # glabel create ab/cd ad0 > # ls -l /dev/label >=20 > I was going to suggest disallowing of '/' in labels but in past such > change has been reverted. >=20 > ------------------------------------------------------------------------ > r149339 | pjd | 2005-08-20 20:05:47 +0300 (Sat, 20 Aug 2005) | 5 lines >=20 > Back-out the change from revision 1.14 and allow for '/' in labels > again. >=20 > Convinced by: green, Gavin Atkinson, dougb, gordon > MFC after: 1 day >=20 > ------------------------------------------------------------------------ >=20 > So it's probably a dead end to try to suggest disallowing of '/'? > Unfortunately it's not easy to fix all problems with directories. For > starters devfs doesn't support removal of directories at all. Well, disallowing '/' in glabel(8) is not going fix devfs, is it?:) What you described are bugs in devfs that should be fixed in devfs and not worked around by limiting GEOM flexibility. Allowing '/' in labels is very useful. Not only labels, you can do the same with gmirror(8), gstripe(8), etc. although with glabel(8) it is more important. Devfs allows to create multiple entiries with the same name and this is bug, file system shouldn't allow that. I'd suggest take the time and fix the bugs properly. It is FreeBSD, so do it right:) --=20 Pawel Jakub Dawidek http://www.wheelsystems.com pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --ncSAzJYg3Aa9+CRW Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (FreeBSD) iEYEARECAAYFAkueylwACgkQForvXbEpPzS7IwCg9TmWyU04nzx6qLgHSN5z1CLz J7YAnj6z1fscqR6JlP3DcBnnngI4kVSV =zZMZ -----END PGP SIGNATURE----- --ncSAzJYg3Aa9+CRW-- From owner-freebsd-geom@FreeBSD.ORG Tue Mar 16 14:12:56 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6B5AA1065675 for ; Tue, 16 Mar 2010 14:12:56 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from gw02.mail.saunalahti.fi (gw02.mail.saunalahti.fi [195.197.172.116]) by mx1.freebsd.org (Postfix) with ESMTP id 2B9DE8FC16 for ; Tue, 16 Mar 2010 14:12:55 +0000 (UTC) Received: from a91-153-117-195.elisa-laajakaista.fi (a91-153-117-195.elisa-laajakaista.fi [91.153.117.195]) by gw02.mail.saunalahti.fi (Postfix) with SMTP id 7DE66139AFF; Tue, 16 Mar 2010 16:12:52 +0200 (EET) Date: Tue, 16 Mar 2010 16:12:51 +0200 From: Jaakko Heinonen To: Ivan Voras Message-ID: <20100316141251.GA3010@a91-153-117-195.elisa-laajakaista.fi> References: <20100313083551.GB966@a91-153-117-195.elisa-laajakaista.fi> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) Cc: freebsd-geom@freebsd.org Subject: Re: Escape unsafe characters for kern.geom.confxml XML dump X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Mar 2010 14:12:56 -0000 On 2010-03-15, Ivan Voras wrote: > Wouldn't it be slightly better (it's not important, really), to use HTML > "entities" instead - & > < ' " ? It's probably a matter of taste. I think I prefer to keep the patch simpler. -- Jaakko From owner-freebsd-geom@FreeBSD.ORG Tue Mar 16 14:17:42 2010 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4CD28106566B; Tue, 16 Mar 2010 14:17:42 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from gw01.mail.saunalahti.fi (gw01.mail.saunalahti.fi [195.197.172.115]) by mx1.freebsd.org (Postfix) with ESMTP id 0F30E8FC1D; Tue, 16 Mar 2010 14:17:41 +0000 (UTC) Received: from a91-153-117-195.elisa-laajakaista.fi (a91-153-117-195.elisa-laajakaista.fi [91.153.117.195]) by gw01.mail.saunalahti.fi (Postfix) with SMTP id AC91815153D; Tue, 16 Mar 2010 16:17:38 +0200 (EET) Date: Tue, 16 Mar 2010 16:17:38 +0200 From: Jaakko Heinonen To: Pawel Jakub Dawidek Message-ID: <20100316141737.GB3010@a91-153-117-195.elisa-laajakaista.fi> References: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> <20100316000133.GC3574@garage.freebsd.pl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20100316000133.GC3574@garage.freebsd.pl> User-Agent: Mutt/1.5.20 (2009-06-14) Cc: freebsd-geom@FreeBSD.org Subject: Re: geom_label and directories under /dev X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Mar 2010 14:17:42 -0000 Thanks for your reply. On 2010-03-16, Pawel Jakub Dawidek wrote: > What you described are bugs in devfs that should be fixed in devfs and > not worked around by limiting GEOM flexibility. I don't disagree in general. > Devfs allows to create multiple entiries with the same name and this > is bug, file system shouldn't allow that. I am not a devfs expert but the current make_dev(9) interface suggest that it's responsibility of the caller to ensure sanity of device names. make_dev(9) can't fail AFAIK, so fixing it seems to require writing a new interface for devfs. Also, changes in GEOM may be needed because g_dev_taste() isn't prepared to handle make_dev() failures. -- Jaakko From owner-freebsd-geom@FreeBSD.ORG Tue Mar 16 14:23:44 2010 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C3C1A1065670; Tue, 16 Mar 2010 14:23:44 +0000 (UTC) (envelope-from phk@critter.freebsd.dk) Received: from phk.freebsd.dk (phk.freebsd.dk [130.225.244.222]) by mx1.freebsd.org (Postfix) with ESMTP id 887F98FC08; Tue, 16 Mar 2010 14:23:44 +0000 (UTC) Received: from critter.freebsd.dk (critter.freebsd.dk [192.168.61.3]) by phk.freebsd.dk (Postfix) with ESMTP id 548596436; Tue, 16 Mar 2010 14:23:43 +0000 (UTC) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.14.3/8.14.3) with ESMTP id o2GENgSe083504; Tue, 16 Mar 2010 14:23:43 GMT (envelope-from phk@critter.freebsd.dk) To: Jaakko Heinonen From: "Poul-Henning Kamp" In-Reply-To: Your message of "Tue, 16 Mar 2010 16:17:38 +0200." <20100316141737.GB3010@a91-153-117-195.elisa-laajakaista.fi> Date: Tue, 16 Mar 2010 14:23:42 +0000 Message-ID: <83503.1268749422@critter.freebsd.dk> Sender: phk@critter.freebsd.dk Cc: Pawel Jakub Dawidek , freebsd-geom@FreeBSD.org Subject: Re: geom_label and directories under /dev X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Mar 2010 14:23:44 -0000 In message <20100316141737.GB3010@a91-153-117-195.elisa-laajakaista.fi>, Jaakko Heinonen writes: > >> Devfs allows to create multiple entiries with the same name and this >> is bug, file system shouldn't allow that. > >I am not a devfs expert but the current make_dev(9) interface suggest >that it's responsibility of the caller to ensure sanity of device names. Correct observation. We could probably change the API today to allow failures, but I would hate to see all the device drivers have to sprout code to try to find an alternative name. But likewise, I am not sure having DEVFS silently append abitrary designators for disabiguation, to duplicate names, is a good idea either, but it may be the least bad idea. Poul-Henning -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. From owner-freebsd-geom@FreeBSD.ORG Tue Mar 16 22:59:05 2010 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CEE591065670; Tue, 16 Mar 2010 22:59:05 +0000 (UTC) (envelope-from avg@icyb.net.ua) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 954918FC14; Tue, 16 Mar 2010 22:59:04 +0000 (UTC) Received: from porto.topspin.kiev.ua (porto-e.starpoint.kiev.ua [212.40.38.100]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id AAA00695; Wed, 17 Mar 2010 00:59:02 +0200 (EET) (envelope-from avg@icyb.net.ua) Received: from localhost.topspin.kiev.ua ([127.0.0.1]) by porto.topspin.kiev.ua with esmtp (Exim 4.34 (FreeBSD)) id 1Nrfj3-000HMu-U6; Wed, 17 Mar 2010 00:59:01 +0200 Message-ID: <4BA00D34.6010107@icyb.net.ua> Date: Wed, 17 Mar 2010 00:59:00 +0200 From: Andriy Gapon User-Agent: Thunderbird 2.0.0.23 (X11/20100211) MIME-Version: 1.0 To: Jaakko Heinonen References: <20100313083551.GB966@a91-153-117-195.elisa-laajakaista.fi> <20100316141251.GA3010@a91-153-117-195.elisa-laajakaista.fi> In-Reply-To: <20100316141251.GA3010@a91-153-117-195.elisa-laajakaista.fi> X-Enigmail-Version: 0.96.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Ivan Voras , freebsd-geom@FreeBSD.org Subject: Re: Escape unsafe characters for kern.geom.confxml XML dump X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Mar 2010 22:59:05 -0000 on 16/03/2010 16:12 Jaakko Heinonen said the following: > On 2010-03-15, Ivan Voras wrote: >> Wouldn't it be slightly better (it's not important, really), to use HTML >> "entities" instead - & > < ' " ? > > It's probably a matter of taste. I think I prefer to keep the patch > simpler. I actually like Ivan's suggestion. I don't see any added complexity but the readability is greatly improved. -- Andriy Gapon From owner-freebsd-geom@FreeBSD.ORG Wed Mar 17 10:07:05 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 603C11065670; Wed, 17 Mar 2010 10:07:05 +0000 (UTC) (envelope-from avg@freebsd.org) Received: from citadel.icyb.net.ua (citadel.icyb.net.ua [212.40.38.140]) by mx1.freebsd.org (Postfix) with ESMTP id 7080A8FC1F; Wed, 17 Mar 2010 10:07:04 +0000 (UTC) Received: from odyssey.starpoint.kiev.ua (alpha-e.starpoint.kiev.ua [212.40.38.101]) by citadel.icyb.net.ua (8.8.8p3/ICyb-2.3exp) with ESMTP id LAA11411; Wed, 17 Mar 2010 11:52:33 +0200 (EET) (envelope-from avg@freebsd.org) Message-ID: <4BA0A660.3000902@freebsd.org> Date: Wed, 17 Mar 2010 11:52:32 +0200 From: Andriy Gapon User-Agent: Thunderbird 2.0.0.23 (X11/20100211) MIME-Version: 1.0 To: freebsd-fs@freebsd.org, freebsd-geom@freebsd.org X-Enigmail-Version: 0.95.7 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: Poul-Henning Kamp , Bruce Evans Subject: g_vfs_open and bread(devvp, ...) X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Mar 2010 10:07:05 -0000 I've given a fresh look to the issue of g_vfs_open and bread(devvp, ...) in filesystem code. This time I hope to present my reasoning more clearly than I did in my previous attempts. For this reason I am omitting historical references and dramatic examples/demonstrations but they are still available upon request (and in archives). I hope that my shortened notation in references to the code and data structures will not be confusing. bread() and the API family it belongs to is an interface to buffer cache system. Buffer cache system can be roughly divided into two parts: cache part and I/O path part. I think that it is understood that both parts must have the same notion of a block size when translating a block number to a byte offset. (If this point is not clear, I can follow up with another essay). In the case of cache code the translation is explicit and simple: A) offset = blkno * bo_bsize In the case of I/O code the translation is not that straightforward, because it can be altered/overridden by bop_strategy which can in turn hook vop_strategy, etc. Let's consider a simple case of a filesystem that: a) connects to a geom provider via g_vfs_open b) doesn't modify anything in devvp->v_bufobj (in particular bo_ops and bo_bsize) c) uses bread(devvp) (e.g. to access an equivalent of superblock, etc) Short overview of geom_vfs glue: 1) g_vfs_open sets devvp->v_bufobj.bo_ops to g_vfs_bufops, where bop_strategy is g_vfs_strategy 2) bo_bsize is set to pp->sectorsize 3) g_vfs_strategy doesn't perform any block-to-offset translation of its own, it expects b_iooffset to be correctly set and passes its value to bio_offset When a filesystem issues bread(devvp) the following happens in the I/O path: I) bread() calls breadn() II) in breadn(): bp->b_iooffset = dbtob(bp->b_blkno), that is b_iooffset is set to blkno * DEV_BSIZE (where DEV_BSIZE is 512) III) breadn() then calls bstrategy() which is a simple wrapper around BO_STRATEGY IV) g_vfs_strategy gets called and, as described in (3) above, it simply passes on b_iooffset value to bio_offset V) thus, a block size used for I/O operation is 512 (DEV_BSIZE) VI) on the other hand, as stated in (A) above, block size used in caching code is bo_bsize Thus, if bo_bsize != DEV_BSIZE, or alternatively said, pp->sectorsize != 512, we have a trouble of data getting cached with incorrect offsets. Additionally, from (V) above we must conclude that a filesystem must specify block numbers in DEV_BSIZE units to bread(devvp, blkno, ...) if the conditions (a), (b), (c) are met. In fact, all such filesystems already do that, because otherwise they would read incorrect data from the media. So, the problem is only with the caching of the data. As such, this issue has little practical effects, because only a small number of reads is done via devvp and only for sufficiently small chunks of data (I hope). fs/udf used to be greatly affected by this issue when it was reading directory nodes via devvp, but that was in the past (prior to 189082). Still I think that we should fix this issue for general code correctness/quality reasons. And also to avoid possible future bugs. As demonstrated by (V) and (VI) above, obvious and easiest fix is to (always) set bo_bsize to DEV_BSIZE in g_vfs_open(): --- a/sys/geom/geom_vfs.c +++ b/sys/geom/geom_vfs.c @@ -179,7 +179,7 @@ g_vfs_open(struct vnode *vp, struct g_consumer **cpp, const char *fsname, int wr bo = &vp->v_bufobj; bo->bo_ops = g_vfs_bufops; bo->bo_private = cp; - bo->bo_bsize = pp->sectorsize; + bo->bo_bsize = DEV_BSIZE; gp->softc = bo; return (error); I tested this change with ufs, udf and cd9660 and haven't observed any regressions. P.S. There might something to changing bread(devvp) convention, so that blkno is expected in sectorsize units. But setting bo_bsize to sectorsize is only a tiny portion of what needs to be changed to make it actually work. -- Andriy Gapon From owner-freebsd-geom@FreeBSD.ORG Wed Mar 17 14:18:56 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 900E7106567B for ; Wed, 17 Mar 2010 14:18:56 +0000 (UTC) (envelope-from paolo.tealdi@polito.it) Received: from polito.it (eracle.polito.it [130.192.3.44]) by mx1.freebsd.org (Postfix) with ESMTP id 241FB8FC12 for ; Wed, 17 Mar 2010 14:18:55 +0000 (UTC) X-ExtScanner: Niversoft's FindAttachments (free) Received: from [130.192.92.26] (HELO bibteo.polito.it) by eracle.polito.it (CommuniGate Pro SMTP 5.2.19) with ESMTPS id 33828018 for freebsd-geom@freebsd.org; Wed, 17 Mar 2010 14:18:53 +0100 X-Mailer: QUALCOMM Windows Eudora Version 7.1.0.9 Date: Wed, 17 Mar 2010 14:18:50 +0100 To: freebsd-geom@freebsd.org From: Paolo Tealdi Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed Message-ID: Subject: Strange "gmirror status" X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Mar 2010 14:18:56 -0000 Dear all, I have a FreeBSD server 6.4 with a mirror (geom mirror) on two disk ATA disk (ad2 and ad3) that had some problems : ad2 apparently for a bus problem, detached himself breaking the mirror. The system continued to work only on ad3. After some days i moved all the disks (also system disk) to another computer. After booting, the server automatically recognized the mirror recreating it from ad2 disk ( that with old data :-( ). While recreating the mirror i successfully managed to restore all the data (it's only a slave mirror). This is the output of the command "gmirror status" during the mirror rebuilding # gmirror status Name Status Components mirror/dati FUNCTIONAL ad2 ad3 xx% (I don't really remember the exact status definition but i'm sure it wasn't "DEGRADED") when finished the rebuilding (6-7 hours after) the gmirror output immediately changed in # gmirror status Name Status Components mirror/dati DEGRADED ad2 ad3 Now, after a reboot, in the system log i see Mar 17 13:44:44 aristarco kernel: GEOM_MIRROR: Device dati created (id=1310146198). Mar 17 13:44:44 aristarco kernel: GEOM_MIRROR: Device dati: provider ad2 detected. Mar 17 13:44:44 aristarco kernel: GEOM_MIRROR: Device dati: provider ad2 activated. Mar 17 13:44:44 aristarco kernel: GEOM_MIRROR: Device dati: provider mirror/dati launched. Mar 17 13:44:44 aristarco kernel: GEOM_MIRROR: Device dati: provider ad3 detected. Mar 17 13:44:44 aristarco kernel: GEOM_MIRROR: Device dati: provider ad3 activated. Mar 17 13:44:44 aristarco kernel: Trying to mount root from ufs:/dev/ad0s1a but the gmirror status (DEGRADED) is not changed. When i write something to the disk, the iostat program is displaying that all the two disk are working and the mirror seems to work. Why the status is not become "COMPLETE" ? Best regards, Paolo Tealdi Ing. Paolo Tealdi Servizi Informatici per le Biblioteche Politecnico Torino Phone : +39-011-0906714 , FAX : +39-011-0906799 C.so Duca degli Abruzzi, 24 - 10129 Torino - ITALY Email : paolo.tealdi(At)polito.it Skype : tealdi.paolo From owner-freebsd-geom@FreeBSD.ORG Wed Mar 17 15:46:41 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 44642106564A for ; Wed, 17 Mar 2010 15:46:41 +0000 (UTC) (envelope-from gcubfg-freebsd-geom@m.gmane.org) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by mx1.freebsd.org (Postfix) with ESMTP id F3A738FC0A for ; Wed, 17 Mar 2010 15:46:40 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1NrvRx-0005yr-2D for freebsd-geom@freebsd.org; Wed, 17 Mar 2010 16:46:25 +0100 Received: from static-78-8-147-77.ssp.dialog.net.pl ([78.8.147.77]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 17 Mar 2010 16:46:25 +0100 Received: from mwisnicki+freebsd by static-78-8-147-77.ssp.dialog.net.pl with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 17 Mar 2010 16:46:25 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-geom@freebsd.org From: Marcin Wisnicki Date: Wed, 17 Mar 2010 15:46:09 +0000 (UTC) Lines: 26 Message-ID: References: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: static-78-8-147-77.ssp.dialog.net.pl User-Agent: Pan/0.132 (Waxed in Black) Subject: Re: geom_label and directories under /dev X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Mar 2010 15:46:41 -0000 On Mon, 15 Mar 2010 21:51:00 +0200, Jaakko Heinonen wrote: > Hi, > > I was working to fix problems with GEOM label class allowing some > problematic label names which can't represent proper files under /dev. > For example: > > - empty label > - "." and ".." > - labels starting or ending with '/' > - labels ending with /.. (Due to a bug for example /..foo/.. is > allowed.) > > So it's probably a dead end to try to suggest disallowing of '/'? > Unfortunately it's not easy to fix all problems with directories. For > starters devfs doesn't support removal of directories at all. > > Opinions? How about using URL encoding scheme[1] for dev names ? That way you will be able to unambigously preserve all characters. The algorithm is very easy, predictable and almost anyone using www is already familiar with it. [1] http://en.wikipedia.org/wiki/Percent-encoding From owner-freebsd-geom@FreeBSD.ORG Wed Mar 17 16:04:18 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F196F1065672 for ; Wed, 17 Mar 2010 16:04:18 +0000 (UTC) (envelope-from pjd@garage.freebsd.pl) Received: from mail.garage.freebsd.pl (chello089077043238.chello.pl [89.77.43.238]) by mx1.freebsd.org (Postfix) with ESMTP id 441F08FC3A for ; Wed, 17 Mar 2010 16:04:17 +0000 (UTC) Received: by mail.garage.freebsd.pl (Postfix, from userid 65534) id 6456645CDC; Wed, 17 Mar 2010 17:04:16 +0100 (CET) Received: from localhost (pdawidek.wheel.pl [10.0.1.1]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.garage.freebsd.pl (Postfix) with ESMTP id 8D2FD456B1; Wed, 17 Mar 2010 17:04:12 +0100 (CET) Date: Wed, 17 Mar 2010 17:04:13 +0100 From: Pawel Jakub Dawidek To: Paolo Tealdi Message-ID: <20100317160413.GC1675@garage.freebsd.pl> References: Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="NU0Ex4SbNnrxsi6C" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i X-PGP-Key-URL: http://people.freebsd.org/~pjd/pjd.asc X-OS: FreeBSD 9.0-CURRENT i386 X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on mail.garage.freebsd.pl X-Spam-Level: X-Spam-Status: No, score=-5.9 required=4.5 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.0.4 Cc: freebsd-geom@freebsd.org Subject: Re: Strange "gmirror status" X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Mar 2010 16:04:19 -0000 --NU0Ex4SbNnrxsi6C Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Mar 17, 2010 at 02:18:50PM +0100, Paolo Tealdi wrote: > when finished the rebuilding (6-7 hours after) the gmirror output=20 > immediately changed in >=20 > # gmirror status > Name Status Components > mirror/dati DEGRADED ad2 > ad3 [...] > Why the status is not become "COMPLETE" ? Maybe you inserted third disk which isn't avilable now? Try: # gmirror dump /dev/ad2 | grep all: If it shows number greater than 2, try: # gmirror forget dati --=20 Pawel Jakub Dawidek http://www.wheelsystems.com pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --NU0Ex4SbNnrxsi6C Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (FreeBSD) iEYEARECAAYFAkug/X0ACgkQForvXbEpPzSlEQCeNjpIeOx2FYdbWMtS0by//aBX VngAoKpcJesHl1RA6Pl14H/Hoo0cn102 =fgky -----END PGP SIGNATURE----- --NU0Ex4SbNnrxsi6C-- From owner-freebsd-geom@FreeBSD.ORG Wed Mar 17 17:02:20 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D3CA01065673; Wed, 17 Mar 2010 17:02:20 +0000 (UTC) (envelope-from paolo.tealdi@polito.it) Received: from polito.it (eracle.polito.it [130.192.3.44]) by mx1.freebsd.org (Postfix) with ESMTP id F2B3A8FC13; Wed, 17 Mar 2010 17:02:17 +0000 (UTC) X-ExtScanner: Niversoft's FindAttachments (free) Received: from [130.192.92.26] (HELO bibteo.polito.it) by eracle.polito.it (CommuniGate Pro SMTP 5.2.19) with ESMTPS id 33836521; Wed, 17 Mar 2010 17:32:17 +0100 X-Mailer: QUALCOMM Windows Eudora Version 7.1.0.9 Date: Wed, 17 Mar 2010 17:32:14 +0100 To: Pawel Jakub Dawidek From: Paolo Tealdi In-Reply-To: <20100317160413.GC1675@garage.freebsd.pl> References: <20100317160413.GC1675@garage.freebsd.pl> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed Message-ID: Cc: freebsd-geom@freebsd.org Subject: Re: Strange "gmirror status" X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Mar 2010 17:02:20 -0000 At 17.04 17/03/2010 +0100, Pawel Jakub Dawidek wrote: >On Wed, Mar 17, 2010 at 02:18:50PM +0100, Paolo Tealdi wrote: > > when finished the rebuilding (6-7 hours after) the gmirror output=20 > > immediately changed in > >=20 > > # gmirror status > > Name Status Components > > mirror/dati DEGRADED ad2 > > ad3 >[...] > > Why the status is not become "COMPLETE" ? > >Maybe you inserted third disk which isn't avilable now? >Try: > > # gmirror dump /dev/ad2 | grep all: > >If it shows number greater than 2, try: > > # gmirror forget dati Not. Never. But doing a # gmirror forget dati the status is immediately become : #gmirror status Name Status Components mirror/dati COMPLETE ad2 ad3 Many many thanks, Paolo Tealdi Ing. Paolo Tealdi Servizi Informatici per le Biblioteche Politecnico Torino Phone : +39-011-0906714 , FAX : +39-011-0906799 C.so Duca degli Abruzzi, 24 - 10129 Torino - ITALY Email : paolo.tealdi(At)polito.it Skype : tealdi.paolo From owner-freebsd-geom@FreeBSD.ORG Wed Mar 17 18:49:27 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4FDCE1065677; Wed, 17 Mar 2010 18:49:27 +0000 (UTC) (envelope-from freebsd@chillt.de) Received: from dd15624.kasserver.com (dd15624.kasserver.com [85.13.136.215]) by mx1.freebsd.org (Postfix) with ESMTP id 12EA28FC21; Wed, 17 Mar 2010 18:49:25 +0000 (UTC) Received: from taiko.lan (84-203-79-36.mysmart.ie [84.203.79.36]) by dd15624.kasserver.com (Postfix) with ESMTP id 8A1062C11E5F1; Wed, 17 Mar 2010 19:49:24 +0100 (CET) Message-ID: <4BA12418.3060008@chillt.de> Date: Wed, 17 Mar 2010 18:48:56 +0000 From: Bartosz Fabianowski User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.1.8) Gecko/20100303 Thunderbird/3.0.3 MIME-Version: 1.0 To: Pawel Jakub Dawidek References: <4B80CEE3.80909@fabianowski.eu> <20100221082508.GL1617@garage.freebsd.pl> In-Reply-To: <20100221082508.GL1617@garage.freebsd.pl> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-geom@freebsd.org Subject: Re: gjournal failing to do its job X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Mar 2010 18:49:27 -0000 > File system should be placed directly on .journal provider. I have recreated all file systems, each on its own journal provider. And gjournal *still* fails to do it job: On a normal boot, all journal providers come up as "clean". If the system hangs and has to be force-rebooted, the journal providers report "consistent" during boot. However, the system still complains that / has not been unmounted cleanly. While it only complains about /, all other file systems are actually not clean either. I can return to a consistent state by running fsck on each file system and fixing the (numerous) errors it reports. But this surely cannot be how journaling is supposed to work... Am I doing something wrong here? I cannot see what. Each file system is UFS2, created directly on its own gjournal provider and with journaling flag set. - Bartosz From owner-freebsd-geom@FreeBSD.ORG Wed Mar 17 22:32:26 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7C13A106566B for ; Wed, 17 Mar 2010 22:32:26 +0000 (UTC) (envelope-from gcubfg-freebsd-geom@m.gmane.org) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by mx1.freebsd.org (Postfix) with ESMTP id 35C4F8FC15 for ; Wed, 17 Mar 2010 22:32:25 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Ns1mq-0008DZ-4Q for freebsd-geom@freebsd.org; Wed, 17 Mar 2010 23:32:24 +0100 Received: from 93-136-34-137.adsl.net.t-com.hr ([93.136.34.137]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 17 Mar 2010 23:32:24 +0100 Received: from ivoras by 93-136-34-137.adsl.net.t-com.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 17 Mar 2010 23:32:24 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-geom@freebsd.org From: Ivan Voras Date: Wed, 17 Mar 2010 23:31:58 +0100 Lines: 14 Message-ID: References: <20100315195059.GA1331@a91-153-117-195.elisa-laajakaista.fi> <20100316000133.GC3574@garage.freebsd.pl> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: 93-136-34-137.adsl.net.t-com.hr User-Agent: Thunderbird 2.0.0.21 (X11/20090612) In-Reply-To: <20100316000133.GC3574@garage.freebsd.pl> Subject: Re: geom_label and directories under /dev X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Mar 2010 22:32:26 -0000 Pawel Jakub Dawidek wrote: > What you described are bugs in devfs that should be fixed in devfs and > not worked around by limiting GEOM flexibility. Allowing '/' in labels > is very useful. Not only labels, you can do the same with gmirror(8), > gstripe(8), etc. although with glabel(8) it is more important. But it's a name, an identifier. It's like saying "*" can suddenly be a part of a C variable name. Besides, there are special cases to consider - what about names containing successive slashes and possibly C escape sequences? I say - sanitize it completely, leave either 7-bit ASCII or UTF-8 (but in both cases strip slashes and characters < 0x20). From owner-freebsd-geom@FreeBSD.ORG Thu Mar 18 19:23:05 2010 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C6A361065670 for ; Thu, 18 Mar 2010 19:23:05 +0000 (UTC) (envelope-from 000.fbsd@quip.cz) Received: from elsa.codelab.cz (elsa.codelab.cz [94.124.105.4]) by mx1.freebsd.org (Postfix) with ESMTP id 82E968FC29 for ; Thu, 18 Mar 2010 19:23:05 +0000 (UTC) Received: from elsa.codelab.cz (localhost.codelab.cz [127.0.0.1]) by elsa.codelab.cz (Postfix) with ESMTP id 6FBFE19E023 for ; Thu, 18 Mar 2010 20:23:03 +0100 (CET) Received: from [192.168.1.2] (r5bb235.net.upc.cz [86.49.61.235]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by elsa.codelab.cz (Postfix) with ESMTPSA id 24B6419E019 for ; Thu, 18 Mar 2010 20:23:01 +0100 (CET) Message-ID: <4BA27D94.4060508@quip.cz> Date: Thu, 18 Mar 2010 20:23:00 +0100 From: Miroslav Lachman <000.fbsd@quip.cz> User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.1.8) Gecko/20100205 SeaMonkey/2.0.3 MIME-Version: 1.0 To: freebsd-geom@FreeBSD.org Content-Type: text/plain; charset=ISO-8859-2; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: 7.3-RC2 - fdisk cannot write or modify sector zero on gmirror - GEOM bug? X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Mar 2010 19:23:05 -0000 I sent this message with subject "Geom not found: "gm0" / Failed to write sector zero" to the freebsd-stable list a week ago, but nobody replied. I did some tests - more on the end of this message. --------------------------------------------------- I just installed 7.3-RC2 amd64 on new server. I created slice s1 (80GB on disk ad4 (500GB), then partitions for system (/, swap, /var, /usr, /tmp) by sysinstall. After base install I created gmirror gm0 as usual (I did it many times). Now I am no longer in datacenter and have only ssh access to this server and I need to create slice s2 with some partitions for data storage, but fdisk failed. fdisk -u /dev/mirror/gm0 At the end, I got this error: Should we write new partition table? [n] y fdisk: Geom not found: "gm0" fdisk: Failed to write sector zero Fdisk failed even if I used sysctl kern.geom.debugflags=16 Question #1 - why 'Geom not found: "gm0"'? Question #2 - is there any way to create slices + partitions on unused space if system is booted from this device? Or is the only way to boot it from some LiveFS / fixit? I found the same question on this list, but without reply http://lists.freebsd.org/pipermail/freebsd-stable/2009-June/050855.html I hope somebody can help / explain it. --------------------------------------------------- Some newer tests. Today I tried it with 7.2 RELEASE under QEMU without gmirror and there is not any problem to write sector zero on to /dev/ad0 I can resize ad0s1 by fdisk with sysctl kern.geom.debugflags=16 (system is booted from ad0s1a) and I can create ad0s2 without any problem. But this is impossible on gmirror with 7.3-RC2. It seems as some bug in GEOM / gmirror for me. Can somebody with GEOM knowledge take a look at it? Miroslav Lachman From owner-freebsd-geom@FreeBSD.ORG Thu Mar 18 19:42:25 2010 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BFA7B106566C for ; Thu, 18 Mar 2010 19:42:25 +0000 (UTC) (envelope-from 000.fbsd@quip.cz) Received: from elsa.codelab.cz (elsa.codelab.cz [94.124.105.4]) by mx1.freebsd.org (Postfix) with ESMTP id F2FE68FC19 for ; Thu, 18 Mar 2010 19:42:24 +0000 (UTC) Received: from elsa.codelab.cz (localhost.codelab.cz [127.0.0.1]) by elsa.codelab.cz (Postfix) with ESMTP id 1161919E031 for ; Thu, 18 Mar 2010 20:42:24 +0100 (CET) Received: from [192.168.1.2] (r5bb235.net.upc.cz [86.49.61.235]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by elsa.codelab.cz (Postfix) with ESMTPSA id 9F81419E02A for ; Thu, 18 Mar 2010 20:42:18 +0100 (CET) Message-ID: <4BA28219.70605@quip.cz> Date: Thu, 18 Mar 2010 20:42:17 +0100 From: Miroslav Lachman <000.fbsd@quip.cz> User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.1.8) Gecko/20100205 SeaMonkey/2.0.3 MIME-Version: 1.0 To: freebsd-geom@FreeBSD.org Content-Type: text/plain; charset=ISO-8859-2; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: 7.3-RC2 GEOM is too verbose X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Mar 2010 19:42:25 -0000 Is there (in 7.3-RC2 amd64) some new GEOM debugging options turned on by default? I see a lot of entries in /var/log/messages on every manipulation with disks / mirror / mounts etc. This is example when I did just two commands: umount /vol0 mount /vol0 (161 lines in messages) Mar 18 20:30:59 vcela kernel: g_wither_geom_close(0xffffff00618efd00(ffs.mirror/gm1s1f)) Mar 18 20:30:59 vcela kernel: g_post_event_x(0xffffffff804d4670, 0xffffff0004724200, 2, 0) Mar 18 20:30:59 vcela kernel: ref 0xffffff0004724200 Mar 18 20:30:59 vcela kernel: g_post_event_x(0xffffffff804d4670, 0xffffff0061d6d100, 2, 0) Mar 18 20:30:59 vcela kernel: ref 0xffffff0061d6d100 Mar 18 20:30:59 vcela kernel: g_post_event_x(0xffffffff804d4670, 0xffffff0004746b00, 2, 0) Mar 18 20:30:59 vcela kernel: ref 0xffffff0004746b00 Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff00618efd00(ffs.mirror/gm1s1f)) Mar 18 20:30:59 vcela kernel: g_label_taste(LABEL, mirror/gm1) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3e6bb00) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3e6bb00) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0061973500(label:taste)) Mar 18 20:30:59 vcela kernel: g_mirror_taste(MIRROR, mirror/gm1) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff007ab23880) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff007ab23880) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0056075800(mirror:taste)) Mar 18 20:30:59 vcela kernel: g_mbrext_taste(MBREXT,mirror/gm1) Mar 18 20:30:59 vcela kernel: g_part_taste(PART,mirror/gm1) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff0061973500(mirror/gm1)) Mar 18 20:30:59 vcela kernel: bsd_taste(BSD,mirror/gm1) Mar 18 20:30:59 vcela kernel: g_slice_spoiled(0xffffff00b3d75c80/mirror/gm1) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff0061701000(mirror/gm1)) Mar 18 20:30:59 vcela kernel: g_label_taste(LABEL, mirror/gm1s1) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3d54800) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3d54800) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0019ef3200(label:taste)) Mar 18 20:30:59 vcela kernel: g_mirror_taste(MIRROR, mirror/gm1s1) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff0004c47a00) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff0004c47a00) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0019a76600(mirror:taste)) Mar 18 20:30:59 vcela kernel: mbr_taste(MBR,mirror/gm1s1) Mar 18 20:30:59 vcela kernel: g_mbrext_taste(MBREXT,mirror/gm1s1) Mar 18 20:30:59 vcela kernel: g_slice_spoiled(0xffffff00b3db4500/mirror/gm1s1) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff0061a9d300(mirror/gm1s1)) Mar 18 20:30:59 vcela kernel: g_part_taste(PART,mirror/gm1s1) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff0056515e00(mirror/gm1s1)) Mar 18 20:30:59 vcela kernel: g_label_taste(LABEL, mirror/gm1s1f) Mar 18 20:30:59 vcela kernel: g_slice_config(mirror/gm1s1f, 0, 1) Mar 18 20:30:59 vcela kernel: g_post_event_x(0xffffffff804d4670, 0xffffff0019fa6b00, 2, 0) Mar 18 20:30:59 vcela kernel: ref 0xffffff0019fa6b00 Mar 18 20:30:59 vcela kernel: ref 0xffffff0061058c00 Mar 18 20:30:59 vcela kernel: g_slice_config(mirror/gm1s1f, 0, 1) Mar 18 20:30:59 vcela kernel: g_post_event_x(0xffffffff804d4670, 0xffffff0019c36500, 2, 0) Mar 18 20:30:59 vcela kernel: ref 0xffffff0019c36500 Mar 18 20:30:59 vcela kernel: ref 0xffffff0056096e00 Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00199d2800) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00199d2800) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0019ff5100(label:taste)) Mar 18 20:30:59 vcela kernel: g_mirror_taste(MIRROR, mirror/gm1s1f) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00613d9580) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00613d9580) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff00618de800(mirror:taste)) Mar 18 20:30:59 vcela kernel: mbr_taste(MBR,mirror/gm1s1f) Mar 18 20:30:59 vcela kernel: g_slice_spoiled(0xffffff00b3d5b900/mirror/gm1s1f) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff0061d68000(mirror/gm1s1f)) Mar 18 20:30:59 vcela kernel: g_mbrext_taste(MBREXT,mirror/gm1s1f) Mar 18 20:30:59 vcela kernel: g_part_taste(PART,mirror/gm1s1f) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff0019b23800(mirror/gm1s1f)) Mar 18 20:30:59 vcela kernel: bsd_taste(BSD,mirror/gm1s1f) Mar 18 20:30:59 vcela kernel: g_slice_spoiled(0xffffff00b3d7de00/mirror/gm1s1f) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff00619ea700(mirror/gm1s1f)) Mar 18 20:30:59 vcela kernel: g_label_taste(LABEL, ufsid/4ba0b065341e9993) Mar 18 20:30:59 vcela kernel: g_mirror_taste(MIRROR, ufsid/4ba0b065341e9993) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3d9a600) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3d9a600) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0061643d00(mirror:taste)) Mar 18 20:30:59 vcela kernel: mbr_taste(MBR,ufsid/4ba0b065341e9993) Mar 18 20:30:59 vcela kernel: g_slice_spoiled(0xffffff00b3db1380/ufsid/4ba0b065341e9993) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff0061b44b00(ufsid/4ba0b065341e9993)) Mar 18 20:30:59 vcela kernel: g_mbrext_taste(MBREXT,ufsid/4ba0b065341e9993) Mar 18 20:30:59 vcela kernel: dev_taste(DEV,ufsid/4ba0b065341e9993) Mar 18 20:30:59 vcela kernel: g_part_taste(PART,ufsid/4ba0b065341e9993) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff00a8408600(ufsid/4ba0b065341e9993)) Mar 18 20:30:59 vcela kernel: bsd_taste(BSD,ufsid/4ba0b065341e9993) Mar 18 20:30:59 vcela kernel: g_slice_spoiled(0xffffff00b3d9ea00/ufsid/4ba0b065341e9993) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff007a2f8500(ufsid/4ba0b065341e9993)) Mar 18 20:30:59 vcela kernel: g_label_taste(LABEL, ufs/webdata) Mar 18 20:30:59 vcela kernel: g_mirror_taste(MIRROR, ufs/webdata) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3de0a00) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3de0a00) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0061643d00(mirror:taste)) Mar 18 20:30:59 vcela kernel: mbr_taste(MBR,ufs/webdata) Mar 18 20:30:59 vcela kernel: g_slice_spoiled(0xffffff00b3da3280/ufs/webdata) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff007a27f800(ufs/webdata)) Mar 18 20:30:59 vcela kernel: g_mbrext_taste(MBREXT,ufs/webdata) Mar 18 20:30:59 vcela kernel: dev_taste(DEV,ufs/webdata) Mar 18 20:30:59 vcela kernel: g_part_taste(PART,ufs/webdata) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff00618de800(ufs/webdata)) Mar 18 20:30:59 vcela kernel: bsd_taste(BSD,ufs/webdata) Mar 18 20:30:59 vcela kernel: g_slice_spoiled(0xffffff00b3de0a00/ufs/webdata) Mar 18 20:30:59 vcela kernel: g_wither_geom(0xffffff0019ff5100(ufs/webdata)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3d92100) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3d92100) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff00618efd00(ffs.mirror/gm1s1f)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3da3280) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3da3280) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff007a27f800(ufs/webdata)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3db1380) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3db1380) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0061b44b00(ufsid/4ba0b065341e9993)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3d5b900) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3d5b900) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0061d68000(mirror/gm1s1f)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3db4500) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3db4500) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0061a9d300(mirror/gm1s1)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3da4d80) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3da4d80) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff00618de800(ufs/webdata)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3ddf380) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3ddf380) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff00a8408600(ufsid/4ba0b065341e9993)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3db8700) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3db8700) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0019b23800(mirror/gm1s1f)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff005b760400) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff005b760400) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0056515e00(mirror/gm1s1)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3db3600) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3db3600) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0061973500(mirror/gm1)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3de0a00) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3de0a00) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0019ff5100(ufs/webdata)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3d9ea00) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3d9ea00) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff007a2f8500(ufsid/4ba0b065341e9993)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3d7de00) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3d7de00) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff00619ea700(mirror/gm1s1f)) Mar 18 20:30:59 vcela kernel: g_detach(0xffffff00b3d75c80) Mar 18 20:30:59 vcela kernel: g_destroy_consumer(0xffffff00b3d75c80) Mar 18 20:30:59 vcela kernel: g_destroy_geom(0xffffff0061701000(mirror/gm1)) Mar 18 20:31:02 vcela kernel: g_post_event_x(0xffffffff804d48c0, 0xffffff0004724200, 2, 0) Mar 18 20:31:02 vcela kernel: ref 0xffffff0004724200 Mar 18 20:31:02 vcela kernel: g_post_event_x(0xffffffff804d48c0, 0xffffff0061d6d100, 2, 0) Mar 18 20:31:02 vcela kernel: ref 0xffffff0061d6d100 Mar 18 20:31:02 vcela kernel: g_post_event_x(0xffffffff804d48c0, 0xffffff0004746b00, 2, 0) Mar 18 20:31:02 vcela kernel: ref 0xffffff0004746b00 Mar 18 20:31:02 vcela kernel: g_slice_spoiled(0xffffff007ab22c00/mirror/gm1s1f) Mar 18 20:31:02 vcela kernel: g_wither_geom(0xffffff0056096e00(mirror/gm1s1f)) Mar 18 20:31:02 vcela kernel: g_orphan_provider(0xffffff0019c36500(ufs/webdata), 6) Mar 18 20:31:02 vcela kernel: g_slice_spoiled(0xffffff00b3d7d080/mirror/gm1s1f) Mar 18 20:31:02 vcela kernel: g_wither_geom(0xffffff0061058c00(mirror/gm1s1f)) Mar 18 20:31:02 vcela kernel: g_orphan_provider(0xffffff0019fa6b00(ufsid/4ba0b065341e9993), 6) Mar 18 20:31:02 vcela kernel: g_orphan_register(ufs/webdata) Mar 18 20:31:02 vcela kernel: g_dev_orphan(0xffffff00b3d7c200(ufs/webdata)) Mar 18 20:31:02 vcela kernel: g_detach(0xffffff00b3d7c200) Mar 18 20:31:02 vcela kernel: g_destroy_consumer(0xffffff00b3d7c200) Mar 18 20:31:02 vcela kernel: g_destroy_geom(0xffffff00a8f16900(ufs/webdata)) Mar 18 20:31:02 vcela kernel: g_orphan_register(ufsid/4ba0b065341e9993) Mar 18 20:31:02 vcela kernel: g_dev_orphan(0xffffff00b3d9f380(ufsid/4ba0b065341e9993)) Mar 18 20:31:02 vcela kernel: g_detach(0xffffff00b3d9f380) Mar 18 20:31:02 vcela kernel: g_destroy_consumer(0xffffff00b3d9f380) Mar 18 20:31:02 vcela kernel: g_destroy_geom(0xffffff0056401900(ufsid/4ba0b065341e9993)) Mar 18 20:31:02 vcela kernel: g_detach(0xffffff007ab22c00) Mar 18 20:31:02 vcela kernel: g_destroy_consumer(0xffffff007ab22c00) Mar 18 20:31:02 vcela kernel: g_destroy_geom(0xffffff0056096e00(mirror/gm1s1f)) Mar 18 20:31:02 vcela kernel: g_detach(0xffffff00b3d7d080) Mar 18 20:31:02 vcela kernel: g_destroy_consumer(0xffffff00b3d7d080) Mar 18 20:31:02 vcela kernel: g_destroy_geom(0xffffff0061058c00(mirror/gm1s1f)) Even simple "gmirror status" puts two entries in messages: Mar 18 20:41:24 vcela kernel: g_post_event_x(0xffffffff804d0a90, 0xffffff0004d7a640, 2, 262144) Mar 18 20:41:24 vcela kernel: g_post_event_x(0xffffffff804d0a90, 0xffffff00047215a0, 2, 262144) I never see something like this in the past. Can it be disabled somehow? Miroslav Lachman From owner-freebsd-geom@FreeBSD.ORG Fri Mar 19 00:14:31 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 877DB106564A for ; Fri, 19 Mar 2010 00:14:31 +0000 (UTC) (envelope-from gcubfg-freebsd-geom@m.gmane.org) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by mx1.freebsd.org (Postfix) with ESMTP id 42DD68FC13 for ; Fri, 19 Mar 2010 00:14:30 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1NsPrB-0004xg-K8 for freebsd-geom@freebsd.org; Fri, 19 Mar 2010 01:14:29 +0100 Received: from 93-138-89-135.adsl.net.t-com.hr ([93.138.89.135]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 19 Mar 2010 01:14:29 +0100 Received: from ivoras by 93-138-89-135.adsl.net.t-com.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 19 Mar 2010 01:14:29 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-geom@freebsd.org From: Ivan Voras Date: Fri, 19 Mar 2010 01:14:12 +0100 Lines: 14 Message-ID: References: <4BA28219.70605@quip.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: 93-138-89-135.adsl.net.t-com.hr User-Agent: Thunderbird 2.0.0.21 (X11/20090612) In-Reply-To: <4BA28219.70605@quip.cz> Subject: Re: 7.3-RC2 GEOM is too verbose X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Mar 2010 00:14:31 -0000 Miroslav Lachman wrote: > Is there (in 7.3-RC2 amd64) some new GEOM debugging options turned on by > Even simple "gmirror status" puts two entries in messages: > > Mar 18 20:41:24 vcela kernel: g_post_event_x(0xffffffff804d0a90, > 0xffffff0004d7a640, 2, 262144) > Mar 18 20:41:24 vcela kernel: g_post_event_x(0xffffffff804d0a90, > 0xffffff00047215a0, 2, 262144) > > I never see something like this in the past. Can it be disabled somehow? What is the value of the kern.geom.debugflags sysctl and did you perhaps set it somewhere manually? From owner-freebsd-geom@FreeBSD.ORG Fri Mar 19 09:23:42 2010 Return-Path: Delivered-To: freebsd-geom@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C18DA106564A; Fri, 19 Mar 2010 09:23:42 +0000 (UTC) (envelope-from 000.fbsd@quip.cz) Received: from elsa.codelab.cz (elsa.codelab.cz [94.124.105.4]) by mx1.freebsd.org (Postfix) with ESMTP id 7F6038FC1B; Fri, 19 Mar 2010 09:23:42 +0000 (UTC) Received: from elsa.codelab.cz (localhost.codelab.cz [127.0.0.1]) by elsa.codelab.cz (Postfix) with ESMTP id 5045A19E023; Fri, 19 Mar 2010 10:23:40 +0100 (CET) Received: from [192.168.1.2] (r5bb235.net.upc.cz [86.49.61.235]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by elsa.codelab.cz (Postfix) with ESMTPSA id 161EF19E019; Fri, 19 Mar 2010 10:23:37 +0100 (CET) Message-ID: <4BA34297.7010108@quip.cz> Date: Fri, 19 Mar 2010 10:23:35 +0100 From: Miroslav Lachman <000.fbsd@quip.cz> User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.1.8) Gecko/20100205 SeaMonkey/2.0.3 MIME-Version: 1.0 To: Ivan Voras References: <4BA28219.70605@quip.cz> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-geom@freebsd.org Subject: Re: 7.3-RC2 GEOM is too verbose X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Mar 2010 09:23:42 -0000 Ivan Voras wrote: > Miroslav Lachman wrote: >> Is there (in 7.3-RC2 amd64) some new GEOM debugging options turned on by > >> Even simple "gmirror status" puts two entries in messages: >> >> Mar 18 20:41:24 vcela kernel: g_post_event_x(0xffffffff804d0a90, >> 0xffffff0004d7a640, 2, 262144) >> Mar 18 20:41:24 vcela kernel: g_post_event_x(0xffffffff804d0a90, >> 0xffffff00047215a0, 2, 262144) >> >> I never see something like this in the past. Can it be disabled somehow? > > What is the value of the kern.geom.debugflags sysctl and did you perhaps > set it somewhere manually? Yes, I forget that debugflags was set to 17 by me few days ago when I tried to solve my "fdisk on gmirror" problem (described in another message in this list). Sorry for the noise, it was my bad. Thank you for your help! Miroslav Lachman From owner-freebsd-geom@FreeBSD.ORG Fri Mar 19 12:43:09 2010 Return-Path: Delivered-To: freebsd-geom@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A2823106564A; Fri, 19 Mar 2010 12:43:09 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 78C3D8FC20; Fri, 19 Mar 2010 12:43:09 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id o2JCh9Yj074741; Fri, 19 Mar 2010 12:43:09 GMT (envelope-from jh@freefall.freebsd.org) Received: (from jh@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id o2JCh94D074737; Fri, 19 Mar 2010 12:43:09 GMT (envelope-from jh) Date: Fri, 19 Mar 2010 12:43:09 GMT Message-Id: <201003191243.o2JCh94D074737@freefall.freebsd.org> To: jh@FreeBSD.org, freebsd-geom@FreeBSD.org, jh@FreeBSD.org From: jh@FreeBSD.org Cc: Subject: Re: kern/104389: [geom] [patch] sys/geom/geom_dump.c doesn't encode XML entities X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Mar 2010 12:43:09 -0000 Synopsis: [geom] [patch] sys/geom/geom_dump.c doesn't encode XML entities Responsible-Changed-From-To: freebsd-geom->jh Responsible-Changed-By: jh Responsible-Changed-When: Fri Mar 19 12:43:09 UTC 2010 Responsible-Changed-Why: Take. http://www.freebsd.org/cgi/query-pr.cgi?pr=104389 From owner-freebsd-geom@FreeBSD.ORG Sat Mar 20 14:03:50 2010 Return-Path: Delivered-To: freebsd-geom@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E94FC1065677; Sat, 20 Mar 2010 14:03:50 +0000 (UTC) (envelope-from brucec@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id BEA1B8FC2C; Sat, 20 Mar 2010 14:03:50 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id o2KE3obB014743; Sat, 20 Mar 2010 14:03:50 GMT (envelope-from brucec@freefall.freebsd.org) Received: (from brucec@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id o2KE3opf014739; Sat, 20 Mar 2010 14:03:50 GMT (envelope-from brucec) Date: Sat, 20 Mar 2010 14:03:50 GMT Message-Id: <201003201403.o2KE3opf014739@freefall.freebsd.org> To: brucec@FreeBSD.org, freebsd-bugs@FreeBSD.org, freebsd-geom@FreeBSD.org From: brucec@FreeBSD.org Cc: Subject: Re: kern/144905: [geom][gpart] panic in gpart_ctlreq when unplugging card reader X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Mar 2010 14:03:51 -0000 Synopsis: [geom][gpart] panic in gpart_ctlreq when unplugging card reader Responsible-Changed-From-To: freebsd-bugs->freebsd-geom Responsible-Changed-By: brucec Responsible-Changed-When: Sat Mar 20 14:03:35 UTC 2010 Responsible-Changed-Why: Over to maintainer(s). http://www.freebsd.org/cgi/query-pr.cgi?pr=144905 From owner-freebsd-geom@FreeBSD.ORG Sat Mar 20 14:17:51 2010 Return-Path: Delivered-To: freebsd-geom@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 732081065670; Sat, 20 Mar 2010 14:17:51 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 48C3E8FC12; Sat, 20 Mar 2010 14:17:51 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id o2KEHp9u024138; Sat, 20 Mar 2010 14:17:51 GMT (envelope-from jh@freefall.freebsd.org) Received: (from jh@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id o2KEHosG024134; Sat, 20 Mar 2010 14:17:50 GMT (envelope-from jh) Date: Sat, 20 Mar 2010 14:17:50 GMT Message-Id: <201003201417.o2KEHosG024134@freefall.freebsd.org> To: jchambers@ucla.edu, jh@FreeBSD.org, freebsd-geom@FreeBSD.org From: jh@FreeBSD.org Cc: Subject: Re: kern/126902: [geom] geom_label: kernel panic during install boot X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Mar 2010 14:17:51 -0000 Synopsis: [geom] geom_label: kernel panic during install boot State-Changed-From-To: feedback->closed State-Changed-By: jh State-Changed-When: Sat Mar 20 14:17:50 UTC 2010 State-Changed-Why: Feedback timeout. Not enough information available. http://www.freebsd.org/cgi/query-pr.cgi?pr=126902 From owner-freebsd-geom@FreeBSD.ORG Sat Mar 20 16:18:20 2010 Return-Path: Delivered-To: freebsd-geom@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B3CB41065672; Sat, 20 Mar 2010 16:18:20 +0000 (UTC) (envelope-from jh@FreeBSD.org) Received: from gw02.mail.saunalahti.fi (gw02.mail.saunalahti.fi [195.197.172.116]) by mx1.freebsd.org (Postfix) with ESMTP id 737548FC1F; Sat, 20 Mar 2010 16:18:16 +0000 (UTC) Received: from a91-153-117-195.elisa-laajakaista.fi (a91-153-117-195.elisa-laajakaista.fi [91.153.117.195]) by gw02.mail.saunalahti.fi (Postfix) with SMTP id EB05F1394F8; Sat, 20 Mar 2010 18:18:11 +0200 (EET) Date: Sat, 20 Mar 2010 18:18:11 +0200 From: Jaakko Heinonen To: Andriy Gapon Message-ID: <20100320161811.GA4167@a91-153-117-195.elisa-laajakaista.fi> References: <20100313083551.GB966@a91-153-117-195.elisa-laajakaista.fi> <20100316141251.GA3010@a91-153-117-195.elisa-laajakaista.fi> <4BA00D34.6010107@icyb.net.ua> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4BA00D34.6010107@icyb.net.ua> User-Agent: Mutt/1.5.20 (2009-06-14) Cc: Ivan Voras , freebsd-geom@FreeBSD.org Subject: Re: Escape unsafe characters for kern.geom.confxml XML dump X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 20 Mar 2010 16:18:20 -0000 Hi, On 2010-03-17, Andriy Gapon wrote: > > On 2010-03-15, Ivan Voras wrote: > >> Wouldn't it be slightly better (it's not important, really), to use HTML > >> "entities" instead - & > < ' " ? > > I actually like Ivan's suggestion. > I don't see any added complexity but the readability is greatly improved. I have committed the patch as is. If you feel that this is important I am not against if someone wants to commit such change. -- Jaakko