<feed xmlns='http://www.w3.org/2005/Atom'>
<title>glusterfs.git/xlators/storage, branch v4.1.4</title>
<subtitle></subtitle>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/'/>
<entry>
<title>posix: disable open/read/write on special files</title>
<updated>2018-09-06T15:03:55+00:00</updated>
<author>
<name>Amar Tumballi</name>
<email>amarts@redhat.com</email>
</author>
<published>2018-09-05T13:33:08+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=39db09af1de261ef3b80ce354e8b1b89a599fd40'/>
<id>39db09af1de261ef3b80ce354e8b1b89a599fd40</id>
<content type='text'>
In the file system, the responsibility w.r.to the block and char device
files is related to only support for 'creating' them (using mknod(2)).

Once the device files are created, the read/write syscalls for the specific
devices are handled by the device driver registered for the specific major
number, and depending on the minor number, it knows where to read from.
Hence, we are at risk of reading contents from devices which are handled
by the host kernel on server nodes.

By disabling open/read/write on the device file, we would be safe with
the bypass one can achieve from client side (using gfapi)

Fixes: bz#1625096

Change-Id: I48c776b0af1cbd2a5240862826d3d8918601e47f
Signed-off-by: Amar Tumballi &lt;amarts@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In the file system, the responsibility w.r.to the block and char device
files is related to only support for 'creating' them (using mknod(2)).

Once the device files are created, the read/write syscalls for the specific
devices are handled by the device driver registered for the specific major
number, and depending on the minor number, it knows where to read from.
Hence, we are at risk of reading contents from devices which are handled
by the host kernel on server nodes.

By disabling open/read/write on the device file, we would be safe with
the bypass one can achieve from client side (using gfapi)

Fixes: bz#1625096

Change-Id: I48c776b0af1cbd2a5240862826d3d8918601e47f
Signed-off-by: Amar Tumballi &lt;amarts@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>server-protocol: don't allow '../' path in 'name'</title>
<updated>2018-09-06T15:00:58+00:00</updated>
<author>
<name>Amar Tumballi</name>
<email>amarts@redhat.com</email>
</author>
<published>2018-08-09T07:30:01+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=2af8e50a55085df7ede57184558029afc46fb8f9'/>
<id>2af8e50a55085df7ede57184558029afc46fb8f9</id>
<content type='text'>
This will prevent any arbitrary file creation through glusterfs
by modifying the client bits.

Also check for the similar flaw inside posix too, so we prevent any
changes in layers in-between.

Fixes: bz#1625095

Signed-off-by: Amar Tumballi &lt;amarts@redhat.com&gt;
Change-Id: Id9fe0ef6e86459e8ed85ab947d977f058c5ae06e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This will prevent any arbitrary file creation through glusterfs
by modifying the client bits.

Also check for the similar flaw inside posix too, so we prevent any
changes in layers in-between.

Fixes: bz#1625095

Signed-off-by: Amar Tumballi &lt;amarts@redhat.com&gt;
Change-Id: Id9fe0ef6e86459e8ed85ab947d977f058c5ae06e
</pre>
</div>
</content>
</entry>
<entry>
<title>posix: remove not supported get/set content</title>
<updated>2018-09-06T14:43:27+00:00</updated>
<author>
<name>Amar Tumballi</name>
<email>amarts@redhat.com</email>
</author>
<published>2018-07-24T11:44:31+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=045a2493704cd3000260a52fc67d06582b2566ef'/>
<id>045a2493704cd3000260a52fc67d06582b2566ef</id>
<content type='text'>
getting and setting a file's content using extended
attribute worked great as a GET/PUT alternative when
an object storage is supported on top of Gluster. But
it needs application changes, and also, it skips some
caching layers.

It is not used over years, and not supported any more.
Removing the dead code.

Fixes: bz#1625102

Change-Id: Ide3b3f1f644f6ca58558bbe45561f346f96b95b7
Signed-off-by: Amar Tumballi &lt;amarts@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
getting and setting a file's content using extended
attribute worked great as a GET/PUT alternative when
an object storage is supported on top of Gluster. But
it needs application changes, and also, it skips some
caching layers.

It is not used over years, and not supported any more.
Removing the dead code.

Fixes: bz#1625102

Change-Id: Ide3b3f1f644f6ca58558bbe45561f346f96b95b7
Signed-off-by: Amar Tumballi &lt;amarts@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>storage/posix: Increment trusted.pgfid in posix_mknod</title>
<updated>2018-08-29T03:41:38+00:00</updated>
<author>
<name>N Balachandran</name>
<email>nbalacha@redhat.com</email>
</author>
<published>2018-08-21T15:27:52+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=9c0e55e061dcba0fadd3a381c974f10bb7dc14fd'/>
<id>9c0e55e061dcba0fadd3a381c974f10bb7dc14fd</id>
<content type='text'>
The value of trusted.pgfid.xx was always set to 1
in posix_mknod. This is incorrect if posix_mknod
calls posix_create_link_if_gfid_exists.

Change-Id: Ibe87ca6f155846b9a7c7abbfb1eb8b6a99a5eb68
fixes: bz#1623317
Signed-off-by: N Balachandran &lt;nbalacha@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The value of trusted.pgfid.xx was always set to 1
in posix_mknod. This is incorrect if posix_mknod
calls posix_create_link_if_gfid_exists.

Change-Id: Ibe87ca6f155846b9a7c7abbfb1eb8b6a99a5eb68
fixes: bz#1623317
Signed-off-by: N Balachandran &lt;nbalacha@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>dht: Delete MDS internal xattr from dict in dht_getxattr_cbk</title>
<updated>2018-08-16T14:31:37+00:00</updated>
<author>
<name>Mohit Agrawal</name>
<email>moagrawa@redhat.com</email>
</author>
<published>2018-05-30T09:39:29+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=b21b83af0baab3c651b6fd2e4657ca66080a7bcb'/>
<id>b21b83af0baab3c651b6fd2e4657ca66080a7bcb</id>
<content type='text'>
Problem: At the time of fetching xattr to heal xattr by afr
         it is not able to fetch xattr because posix_getxattr
         has a check to ignore if xattr name is MDS

Solution: To ignore same xattr update a check in dht_getxattr_cbk
          instead of having a check in posix_getxattr

Backport of:
 &gt; BUG: 1584098
 &gt; Change-Id: I86cd2b2ee08488cb6c12f407694219d57c5361dc
 &gt; Signed-off-by: Mohit Agrawal &lt;moagrawa@redhat.com&gt;

Change-Id: I86cd2b2ee08488cb6c12f407694219d57c5361dc
fixes: bz#1611116
Signed-off-by: Mohit Agrawal &lt;moagrawa@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem: At the time of fetching xattr to heal xattr by afr
         it is not able to fetch xattr because posix_getxattr
         has a check to ignore if xattr name is MDS

Solution: To ignore same xattr update a check in dht_getxattr_cbk
          instead of having a check in posix_getxattr

Backport of:
 &gt; BUG: 1584098
 &gt; Change-Id: I86cd2b2ee08488cb6c12f407694219d57c5361dc
 &gt; Signed-off-by: Mohit Agrawal &lt;moagrawa@redhat.com&gt;

Change-Id: I86cd2b2ee08488cb6c12f407694219d57c5361dc
fixes: bz#1611116
Signed-off-by: Mohit Agrawal &lt;moagrawa@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>storage/posix: Fix excessive logging in WRITE fop path</title>
<updated>2018-08-10T05:39:27+00:00</updated>
<author>
<name>Krutika Dhananjay</name>
<email>kdhananj@redhat.com</email>
</author>
<published>2018-06-13T06:56:55+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=6087f73c04797867cf65092174542672b391b21a'/>
<id>6087f73c04797867cf65092174542672b391b21a</id>
<content type='text'>
        Backport of: https://review.gluster.org/#/c/glusterfs/+/20250

I was running some write-intensive tests on my volume, and in a matter
of 2 hrs, the 50GB space in my root partition was exhausted. On inspecting
further, figured that excessive logging in bricks was the cause -
specifically in posix write when posix_check_internal_writes() does
dict_get() without a NULL-check on xdata.

Change-Id: I89de57a3a90ca5c375e5b9477801a9e5ff018bbf
fixes: bz#1596686
Signed-off-by: Krutika Dhananjay &lt;kdhananj@redhat.com&gt;
(cherry picked from commit 81701e4d92ae7b1d97e5bc955703719f2e9e773a)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
        Backport of: https://review.gluster.org/#/c/glusterfs/+/20250

I was running some write-intensive tests on my volume, and in a matter
of 2 hrs, the 50GB space in my root partition was exhausted. On inspecting
further, figured that excessive logging in bricks was the cause -
specifically in posix write when posix_check_internal_writes() does
dict_get() without a NULL-check on xdata.

Change-Id: I89de57a3a90ca5c375e5b9477801a9e5ff018bbf
fixes: bz#1596686
Signed-off-by: Krutika Dhananjay &lt;kdhananj@redhat.com&gt;
(cherry picked from commit 81701e4d92ae7b1d97e5bc955703719f2e9e773a)
</pre>
</div>
</content>
</entry>
<entry>
<title>afr: switch lk_owner only when pre-op succeeds</title>
<updated>2018-07-23T23:42:15+00:00</updated>
<author>
<name>Ravishankar N</name>
<email>ravishankar@redhat.com</email>
</author>
<published>2018-07-17T15:05:42+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=a8156e843e651be7c18e9e24d08116f752227a35'/>
<id>a8156e843e651be7c18e9e24d08116f752227a35</id>
<content type='text'>
Problem:
In a disk full scenario, we take a failure path in afr_transaction_perform_fop()
and go to unlock phase. But we change the lk-owner before that, causing unlock
to fail. When mount issues another fop that takes locks on that file, it hangs.

Fix:
Change lk-owner only when we are about to perform the fop phase.
Also fix the same issue for arbiters when afr_txn_arbitrate_fop() fails the fop.

Also removed the DISK_SPACE_CHECK_AND_GOTO in posix_xattrop. Otherwise truncate
to zero will fail pre-op phase with ENOSPC when the user is actually trying to
freee up space.

Change-Id: Ic4c8a596b4cdf4a7fc189bf00b561113cf114353
fixes: bz#1603056
Signed-off-by: Ravishankar N &lt;ravishankar@redhat.com&gt;
(cherry picked from commit ec0d7d77de3e4bd485a4fa2e53c9137e25c71ce7)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem:
In a disk full scenario, we take a failure path in afr_transaction_perform_fop()
and go to unlock phase. But we change the lk-owner before that, causing unlock
to fail. When mount issues another fop that takes locks on that file, it hangs.

Fix:
Change lk-owner only when we are about to perform the fop phase.
Also fix the same issue for arbiters when afr_txn_arbitrate_fop() fails the fop.

Also removed the DISK_SPACE_CHECK_AND_GOTO in posix_xattrop. Otherwise truncate
to zero will fail pre-op phase with ENOSPC when the user is actually trying to
freee up space.

Change-Id: Ic4c8a596b4cdf4a7fc189bf00b561113cf114353
fixes: bz#1603056
Signed-off-by: Ravishankar N &lt;ravishankar@redhat.com&gt;
(cherry picked from commit ec0d7d77de3e4bd485a4fa2e53c9137e25c71ce7)
</pre>
</div>
</content>
</entry>
<entry>
<title>posix: check before removing stale symlink</title>
<updated>2018-07-23T23:41:37+00:00</updated>
<author>
<name>Ravishankar N</name>
<email>ravishankar@redhat.com</email>
</author>
<published>2018-07-14T04:35:41+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=d720904046cd665977dcd312e49bc3908568859b'/>
<id>d720904046cd665977dcd312e49bc3908568859b</id>
<content type='text'>
BZ 1564071 complains of directories with missing gfid symlinks and
corresponding "Found stale gfid handle" messages in the logs. Hence
add a check to see if the symlink points to an actual directory before
removing it.

Note: Removing stale symlinks was added via commit
3e9a9c029fac359477fb26d9cc7803749ba038b2

Change-Id: I5d91fab8e5f3a621a9ecad4a1f9c898a3c2d346a
Updates: bz#1603099
Signed-off-by: Ravishankar N &lt;ravishankar@redhat.com&gt;
(cherry picked from commit 9ab218be5e69b9f71fe4eea9ca8d114b78cafd25)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
BZ 1564071 complains of directories with missing gfid symlinks and
corresponding "Found stale gfid handle" messages in the logs. Hence
add a check to see if the symlink points to an actual directory before
removing it.

Note: Removing stale symlinks was added via commit
3e9a9c029fac359477fb26d9cc7803749ba038b2

Change-Id: I5d91fab8e5f3a621a9ecad4a1f9c898a3c2d346a
Updates: bz#1603099
Signed-off-by: Ravishankar N &lt;ravishankar@redhat.com&gt;
(cherry picked from commit 9ab218be5e69b9f71fe4eea9ca8d114b78cafd25)
</pre>
</div>
</content>
</entry>
<entry>
<title>posix/ctime: Fix differential ctime duing entry operations</title>
<updated>2018-07-02T17:27:52+00:00</updated>
<author>
<name>Kotresh HR</name>
<email>khiremat@redhat.com</email>
</author>
<published>2018-06-14T05:08:35+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=0bd0e7c2b4508cf0fff68bd14e3947287a17e875'/>
<id>0bd0e7c2b4508cf0fff68bd14e3947287a17e875</id>
<content type='text'>
We should not be relying on backend file's time attributes
to load the initial ctime time attribute structure. This
is incorrect as each replica set would have witnessed the
file creation at different times.

For new file creation, ctime, atime and mtime should be
same, hence initiate the ctime structure with the time
from the frame. But for the files which were created
before ctime feature is enabled, this is not accurate
but still fine as the times would get eventually accurate.

Backport of:
  &gt; Patch: https://review.gluster.org/#/c/20281/
  &gt; BUG: 1592275
  &gt; Change-Id: I206a469c83ee7b26da2fe096ae7bf8ff5986ad67
  &gt; Signed-off-by: Kotresh HR &lt;khiremat@redhat.com&gt;
  (cherry picked from commit 841991130c94e3fcf4076917be6da9ce90406932)

fixes: bz#1593537
Change-Id: I206a469c83ee7b26da2fe096ae7bf8ff5986ad67
Signed-off-by: Kotresh HR &lt;khiremat@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We should not be relying on backend file's time attributes
to load the initial ctime time attribute structure. This
is incorrect as each replica set would have witnessed the
file creation at different times.

For new file creation, ctime, atime and mtime should be
same, hence initiate the ctime structure with the time
from the frame. But for the files which were created
before ctime feature is enabled, this is not accurate
but still fine as the times would get eventually accurate.

Backport of:
  &gt; Patch: https://review.gluster.org/#/c/20281/
  &gt; BUG: 1592275
  &gt; Change-Id: I206a469c83ee7b26da2fe096ae7bf8ff5986ad67
  &gt; Signed-off-by: Kotresh HR &lt;khiremat@redhat.com&gt;
  (cherry picked from commit 841991130c94e3fcf4076917be6da9ce90406932)

fixes: bz#1593537
Change-Id: I206a469c83ee7b26da2fe096ae7bf8ff5986ad67
Signed-off-by: Kotresh HR &lt;khiremat@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ctime: Fix self heal of symlink in EC volume</title>
<updated>2018-07-02T17:14:15+00:00</updated>
<author>
<name>Kotresh HR</name>
<email>khiremat@redhat.com</email>
</author>
<published>2018-06-18T17:40:33+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=695470765d4d047102fc9d2db7574a6fdb2b3eb3'/>
<id>695470765d4d047102fc9d2db7574a6fdb2b3eb3</id>
<content type='text'>
Since IEEE Std 1003.1-2001 does not require any
association of file times with symbolic links,
there is no requirement that file times be
updated by readlink() states [1].

stat on symlink file was generating a readlink
fop on one of the subvolumes of ec set which
in turn updates atime on that subvolume. This
causes mdata xattr to be different across ec
set and hence self heal fails. So based on [1],
atime is no longer updated by readlink fop.

[1] http://pubs.opengroup.org/onlinepubs/009695399/functions/readlink.html

Backport of:
  &gt; Patch: https://review.gluster.org/#/c/20311/
  &gt; BUG: 1592509
  &gt; Change-Id: I08bd3ca3bdb222bd18160b1aa58fc2f7630c8083
  &gt; Signed-off-by: Kotresh HR &lt;khiremat@redhat.com&gt;
  (cherry picked from commit c097a7894d458e33a41f6db6092677108ef30fec)

fixes: bz#1593536
Change-Id: I08bd3ca3bdb222bd18160b1aa58fc2f7630c8083
Signed-off-by: Kotresh HR &lt;khiremat@redhat.com&gt;
(cherry picked from commit c097a7894d458e33a41f6db6092677108ef30fec)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Since IEEE Std 1003.1-2001 does not require any
association of file times with symbolic links,
there is no requirement that file times be
updated by readlink() states [1].

stat on symlink file was generating a readlink
fop on one of the subvolumes of ec set which
in turn updates atime on that subvolume. This
causes mdata xattr to be different across ec
set and hence self heal fails. So based on [1],
atime is no longer updated by readlink fop.

[1] http://pubs.opengroup.org/onlinepubs/009695399/functions/readlink.html

Backport of:
  &gt; Patch: https://review.gluster.org/#/c/20311/
  &gt; BUG: 1592509
  &gt; Change-Id: I08bd3ca3bdb222bd18160b1aa58fc2f7630c8083
  &gt; Signed-off-by: Kotresh HR &lt;khiremat@redhat.com&gt;
  (cherry picked from commit c097a7894d458e33a41f6db6092677108ef30fec)

fixes: bz#1593536
Change-Id: I08bd3ca3bdb222bd18160b1aa58fc2f7630c8083
Signed-off-by: Kotresh HR &lt;khiremat@redhat.com&gt;
(cherry picked from commit c097a7894d458e33a41f6db6092677108ef30fec)
</pre>
</div>
</content>
</entry>
</feed>
