Re: [dm-devel] PR API fixes for multipathing

2016-07-15 Thread Christoph Hellwig
On Fri, Jul 15, 2016 at 03:03:54PM -0400, Martin K. Petersen wrote: > > "Christoph" == Christoph Hellwig writes: > > Christoph> I was a bit overeager to thing ALL_TG_PT would solve all our > Christoph> multipathing woes in respect to persistent reservation. > Christoph> Turns

Re: [dm-devel] System freezes after OOM

2016-07-15 Thread Mikulas Patocka
On Fri, 15 Jul 2016, David Rientjes wrote: > Kworkers are processing writeback, ext4_writepages() relies on kmem that ext4_writepages is above device mapper, not below, so how it could block device mapper progress? Do you use device mapper on the top of block loop device? Writing to loop

Re: [dm-devel] System freezes after OOM

2016-07-15 Thread David Rientjes
On Fri, 15 Jul 2016, Mikulas Patocka wrote: > And what about the oom reaper? It should have freed all victim's pages > even if the victim is looping in mempool_alloc. Why the oom reaper didn't > free up memory? > Is that possible with mlock or shared memory? Nope. The oom killer does not

Re: [dm-devel] System freezes after OOM

2016-07-15 Thread Mikulas Patocka
On Fri, 15 Jul 2016, David Rientjes wrote: > On Fri, 15 Jul 2016, Mikulas Patocka wrote: > > > > There is no guarantee that _anything_ can return memory to the mempool, > > > > You misunderstand mempools if you make such claims. > > > > There is in fact guarantee that objects will be

Re: [dm-devel] [PATCH V6 0/3] Introducing multipath C API

2016-07-15 Thread Benjamin Marzinski
On Tue, Jul 12, 2016 at 02:50:35PM +0800, Gris Ge wrote: ACK, with my comment on patch 1/3 -Ben > Changes since V5: > * Fix commit message typo of patch 1/3: > 'EINVA vs EINVAL' and 'dedicate vs dedicated' > * Use $(LN) and $(RM) in Makefile in patch 3/3. > * Rebased to current

Re: [dm-devel] [PATCH V6 1/3] multipath-tools: New way to limit the IPC command length.

2016-07-15 Thread Benjamin Marzinski
On Tue, Jul 12, 2016 at 02:50:36PM +0800, Gris Ge wrote: The only thing that I wonder about with this patch is, when previously the multipath client code would have failed with EPIPE, and (at least in some cases) spit out a semi-useful message, the program will now terminate because of the

[dm-devel] [PATCH] dm-crypt: increase mempool size

2016-07-15 Thread Mikulas Patocka
Increase mempool size from 16 to 64 entries. When swapping to dm-crypt, all available memory is temporarily exhausted and dm-crypt is only using the mempool reserve. Increasing mempool reserve improves swapping performance. Signed-off-by: Mikulas Patocka Index:

Re: [dm-devel] write directly to device mapper snapshot origin device ?

2016-07-15 Thread Navin P.S
On Fri, Jul 15, 2016 at 6:14 PM, Zdenek Kabelac wrote: > Dne 15.7.2016 v 14:40 Navin P.S napsal(a): > >> On Fri, Jul 15, 2016 at 6:05 PM, Zdenek Kabelac >> wrote: >>> >>> Dne 15.7.2016 v 14:15 Navin P.S napsal(a): >>> On Fri, Jul 15, 2016 at 5:21

Re: [dm-devel] poor thin performance, relative to thick

2016-07-15 Thread Mike Snitzer
On Thu, Jul 14 2016 at 12:21am -0400, Jon Bernard wrote: > Do you have any intuition on where to start looking? Joe asked me a very basic/obvious question: is block zeroing enabled? (block zeroing is enabled by default -- you have to know to disable it) If zeroing wasn't

Re: [dm-devel] System freezes after OOM

2016-07-15 Thread Mikulas Patocka
On Fri, 15 Jul 2016, Michal Hocko wrote: > On Fri 15-07-16 08:11:22, Mikulas Patocka wrote: > > > > The stacktraces showed that the kcryptd process was throttled when it > > tried to do mempool allocation. Mempool adds the __GFP_NORETRY flag to the > > allocation, but unfortunatelly, this

Re: [dm-devel] dm: fix parameter to blk_delay_queue()

2016-07-15 Thread Mike Snitzer
On Fri, Jul 15 2016 at 9:27am -0400, Tahsin Erdogan wrote: > Second parameter to blk_delay_queue() must be in msec units not jiffies. > > Signed-off-by: Tahsin Erdogan This needs to be rebased against linux-next (or linux-dm.git's 'for-next') because the

Re: [dm-devel] write directly to device mapper snapshot origin device ?

2016-07-15 Thread Mikulas Patocka
> Are origin devices readonly ? > > When i do dd if=/dev/zero of=/dev/mapper/ff count=10, it kills all the > process says OOM. > > How do you go about debugging this ? I'm running 4.7.0-rc7+ . Find some older kernel where this worked. Use the git bisect tool on the kernel tree to find out

Re: [dm-devel] write directly to device mapper snapshot origin device ?

2016-07-15 Thread Zdenek Kabelac
Dne 15.7.2016 v 14:40 Navin P.S napsal(a): On Fri, Jul 15, 2016 at 6:05 PM, Zdenek Kabelac wrote: Dne 15.7.2016 v 14:15 Navin P.S napsal(a): On Fri, Jul 15, 2016 at 5:21 PM, Mikulas Patocka wrote: On Fri, 15 Jul 2016, Navin P.S wrote: Resend

Re: [dm-devel] write directly to device mapper snapshot origin device ?

2016-07-15 Thread Navin P.S
On Fri, Jul 15, 2016 at 6:05 PM, Zdenek Kabelac wrote: > Dne 15.7.2016 v 14:15 Navin P.S napsal(a): > >> On Fri, Jul 15, 2016 at 5:21 PM, Mikulas Patocka >> wrote: >>> >>> >>> >>> On Fri, 15 Jul 2016, Navin P.S wrote: >>> Resend .. On Thu,

Re: [dm-devel] write directly to device mapper snapshot origin device ?

2016-07-15 Thread Zdenek Kabelac
Dne 15.7.2016 v 14:15 Navin P.S napsal(a): On Fri, Jul 15, 2016 at 5:21 PM, Mikulas Patocka wrote: On Fri, 15 Jul 2016, Navin P.S wrote: Resend .. On Thu, Jul 14, 2016 at 7:55 PM, Navin P.S wrote: Hi, Can i do dd if=/dev/zero

Re: [dm-devel] System freezes after OOM

2016-07-15 Thread Michal Hocko
On Fri 15-07-16 08:11:22, Mikulas Patocka wrote: > > > On Fri, 15 Jul 2016, Michal Hocko wrote: > > > On Thu 14-07-16 13:35:35, Mikulas Patocka wrote: > > > On Thu, 14 Jul 2016, Michal Hocko wrote: > > > > On Thu 14-07-16 10:00:16, Mikulas Patocka wrote: > > > > > But it needs other changes to

Re: [dm-devel] System freezes after OOM

2016-07-15 Thread Mikulas Patocka
On Fri, 15 Jul 2016, Michal Hocko wrote: > On Thu 14-07-16 13:35:35, Mikulas Patocka wrote: > > On Thu, 14 Jul 2016, Michal Hocko wrote: > > > On Thu 14-07-16 10:00:16, Mikulas Patocka wrote: > > > > But it needs other changes to honor the PF_LESS_THROTTLE flag: > > > > > > > > static int

Re: [dm-devel] write directly to device mapper snapshot origin device ?

2016-07-15 Thread Mikulas Patocka
On Fri, 15 Jul 2016, Navin P.S wrote: > Resend .. > > On Thu, Jul 14, 2016 at 7:55 PM, Navin P.S wrote: > > Hi, > > Can i do dd if=/dev/zero of=/dev/mapper/dmo count=20 ? where dmo is > > a dm snapshot origin created through dmsetup command. Instead of > > /dev/zero i

Re: [dm-devel] System freezes after OOM

2016-07-15 Thread Mikulas Patocka
On Thu, 14 Jul 2016, David Rientjes wrote: > There is no guarantee that _anything_ can return memory to the mempool, You misunderstand mempools if you make such claims. There is in fact guarantee that objects will be returned to mempool. In the past I reviewed device mapper thoroughly to

Re: [dm-devel] [PATCH 2/3] multipath-tools: merge OPTFLAGS into CFLAGS

2016-07-15 Thread Hannes Reinecke
On 07/08/2016 06:28 PM, Xose Vazquez Perez wrote: > OPTFLAGS is not used anywhere, but maybe it's intrusive for distributions. > > Cc: Mathieu Trudel-Lapierre > Cc: Dragan Stancevic > Cc: Louis Bouchard

Re: [dm-devel] Page Allocation Failures/OOM with dm-crypt on software RAID10 (Intel Rapid Storage)

2016-07-15 Thread Tetsuo Handa
On 2016/07/13 22:47, Michal Hocko wrote: > On Wed 13-07-16 15:18:11, Matthias Dahl wrote: >> I tried to figure this out myself but >> couldn't find anything -- what does the number "-3" state? It is the >> position in some chain or has it a different meaning? > > $ git grep

Re: [dm-devel] System freezes after OOM

2016-07-15 Thread Michal Hocko
On Thu 14-07-16 13:35:35, Mikulas Patocka wrote: > On Thu, 14 Jul 2016, Michal Hocko wrote: > > On Thu 14-07-16 10:00:16, Mikulas Patocka wrote: > > > But it needs other changes to honor the PF_LESS_THROTTLE flag: > > > > > > static int current_may_throttle(void) > > > { > > > return

Re: [dm-devel] write directly to device mapper snapshot origin device ?

2016-07-15 Thread Navin P.S
Resend .. On Thu, Jul 14, 2016 at 7:55 PM, Navin P.S wrote: > Hi, > Can i do dd if=/dev/zero of=/dev/mapper/dmo count=20 ? where dmo is > a dm snapshot origin created through dmsetup command. Instead of > /dev/zero i can write valid devices. > > I could create the dmo

Re: [dm-devel] Page Allocation Failures/OOM with dm-crypt on software RAID10 (Intel Rapid Storage) with check/repair/sync

2016-07-15 Thread Matthias Dahl
Hello... I am rather persistent (stubborn?) when it comes to tracking down bugs, if somehow possible... and it seems it paid off... somewhat. ;-) So I did quite a lot more further tests and came up with something very interesting: As long as the RAID is in sync (as-in: sync_action=idle), I can

[dm-devel] [PATCH 0/3] sysfs prioritizer

2016-07-15 Thread Hannes Reinecke
Hi all, this is a resend of a previous patchset for adding a 'sysfs' prioritizer. This prioritizer uses the sysfs attributes 'access_state' and 'exclusive_pref_bit' to generate the path priority. Priority values are identical to those from the 'alua' prioritizer. Note: the mentioned sysfs

[dm-devel] [PATCH 3/3] multipathd: Add 'sysfs' prioritizer

2016-07-15 Thread Hannes Reinecke
Recent kernels have an 'access_state' attribute which allows us to read the asymmetric access state directly from sysfs. Signed-off-by: Hannes Reinecke --- libmultipath/discovery.c | 33 + libmultipath/discovery.h | 2 ++

[dm-devel] [PATCH 1/3] libmultipath: call get_vpd_uid() if no uid_attribute is set

2016-07-15 Thread Hannes Reinecke
If the uid_attribute is unset we should be calling get_vpd_uid() directly without waiting for retrigger udev events. Signed-off-by: Hannes Reinecke --- libmultipath/discovery.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libmultipath/discovery.c

[dm-devel] [PATCH 2/3] alua prioritizer: Fix typo 'perf'

2016-07-15 Thread Hannes Reinecke
The bit is called the 'preferred_path' bit. Nothing do to with performance. Signed-off-by: Hannes Reinecke --- libmultipath/prioritizers/alua.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libmultipath/prioritizers/alua.c