Hello John,

Your "Swift on PI" instructions helped me a lot when I started my
attempt to get Swift running on the RPi3. I documented here what I
did:

https://github.com/christianbaun/s3perf/wiki/Swift-on-a-Raspberry-Pi-3-with-Raspbian-(Debian-Jessie-8.0)

I use the user pi and specified this in all configuration conf-files
inside /etc/swift. In order to get rid of the "Permission denied"
issue, i even gave /mnt/sdb1 and all subfolder full access privileges:

$ sudo chown -R pi:pi /mnt/sdb1/
$ sudo chmod -R 777 /mnt/sdb1/
$ mount | grep sdb1
/srv/swift-disk on /mnt/sdb1 type xfs
(rw,noatime,nodiratime,attr2,nobarrier,inode64,logbufs=8,noquota)

But the situation did not change. I can create buckets, but not upload objects.

Best Regards
   Christian



2017-05-24 18:07 GMT+02:00 John Dickinson <m...@not.mn>:
>
>
> On 24 May 2017, at 5:47, Christian Baun wrote:
>
>> Hello all,
>>
>> I tried again to install Swift only ontop of a Raspberry Pi 3 with
>
> So, first off, I think that's really cool. I tried something like this a 
> while back, too. https://github.com/notmyname/swift_on_pi
>
> However, you can see that since it was last updated in early 2013, it's not 
> been something I've spend a lot of time maintaining ;-)
>
>> Rapbian and I followed this time the instructions "SAIO - Swift All In
>> One"
>>
>> https://docs.openstack.org/developer/swift/development_saio.html
>>
>> The installation went well and the service is running, but I still
>> cannot upload files into the service. The error message is still this
>> one on client side:
>>
>> Object PUT failed:
>> http://10.0.0.253:8080/v1/AUTH_test/s3perf-testbucket/testfiles/s3perf-testfile1.txt
>> 503 Service Unavailable  [first 60 chars of response]
>> <html><h1>Service Unavailable</h1><p>The server is currently
>>
>> and this one inside the file storage1.error:
>>
>> May 24 13:15:15 raspberrypi object-server: ERROR __call__ error with PUT
>> /sdb1/484/AUTH_test/s3perf-testbucket/testfiles/s3perf-testfile1.txt :
>> #012Traceback (most recent call last):#012  File
>> "/home/pi/swift/swift/obj/server.py", line 1105, in __call__#012    res =
>> getattr(self, req.method)(req)#012  File
>> "/home/pi/swift/swift/common/utils.py", line 1626, in _timing_stats#012
>> resp = func(ctrl, *args, **kwargs)#012  File
>> "/home/pi/swift/swift/obj/server.py", line 814, in PUT#012
>> writer.put(metadata)#012  File "/home/pi/swift/swift/obj/diskfile.py",
>> line 2561, in put#012    super(DiskFileWriter, self)._put(metadata,
>> True)#012  File "/home/pi/swift/swift/obj/diskfile.py", line 1566, in
>>  _put#012    tpool_reraise(self._finalize_put, metadata, target_path,
>> cleanup)#012  File "/home/pi/swift/swift/common/utils.py", line 3536, in
>> tpool_reraise#012    raise resp#012IOError: [Errno 13] Permission denied
>> (txn: txdfe3c7f704be4af8817b3-0059256b43)
>>
>> I tried the installation instructions inside virtual machine with
>> Ubuntu 14.04 and there is no problem. The service runs and I can
>> upload files without any error.
>>
>> Has anybody here an idea how to locate the root cause of this issue
>> and how to fix it?
>
> You've done some good first steps. To state the obvious, there's some 
> permissions problems somewhere. Probably something to do with the way the 
> drive is mounted. If you're running it as the "swift" user, make sure the 
> mounted drive is also owned by the swift user.
>
>>
>> Best Regards
>>    Christian
>>
>> ---------- Forwarded message ----------
>> From: Christian Baun <christianb...@web.de>
>> Date: 2017-05-10 20:03 GMT+02:00
>> Subject: Unable to upload a file into OpenStack Swift because of
>> "[Errno 13] Permission denied"
>> To: openstack@lists.openstack.org
>>
>>
>> Hello,
>>
>> Creating and erasing buckets (containers) in my single node Swift only
>> installation works well, but any attempt to upload a file causes just
>> an error message.
>>
>> $ tail -f /var/log/swift/storage1.error
>> ...
>> May  9 14:03:10 raspberrypi object-server: ERROR __call__ error with
>> PUT /d1/237/AUTH_test/s3perf/s3perf-testfile1.txt : #012Traceback
>> (most recent call last):#012  File
>> "/home/pi/swift/swift/obj/server.py", line 1105, in __call__#012
>> res = getattr(self, req.method)(req)#012  File
>> "/home/pi/swift/swift/common/utils.py", line 1626, in
>> _timing_stats#012    resp = func(ctrl, *args, **kwargs)#012  File
>> "/home/pi/swift/swift/obj/server.py", line 814, in PUT#012
>> writer.put(metadata)#012  File "/home/pi/swift/swift/obj/diskfile.py",
>> line 2561, in put#012    super(DiskFileWriter, self)._put(metadata,
>> True)#012  File "/home/pi/swift/swift/obj/diskfile.py", line 1566, in
>> _put#012    tpool_reraise(self._finalize_put, metadata, target_path,
>> cleanup)#012  File "/home/pi/swift/swift/common/utils.py", line 3536,
>> in tpool_reraise#012    raise resp#012IOError: [Errno 13] Permission
>> denied (txn: txb986cc22c54f426c8289b-005911affd)
>>
>> I have started Swift as user pi and assigned these folders to this user:
>>
>> $ sudo chown pi:pi /etc/swift
>> $ sudo chown -R pi:pi /mnt/sdb1/*
>> $ sudo chown -R pi:pi /var/cache/swift
>> $ sudo chown -R pi:pi /var/run/swift
>>
>> sdb1 is a loopback device with the XFS file system.
>>
>> I deployed Swift this way:
>> https://github.com/christianbaun/s3perf/wiki/Swift-on-a-Raspberry-Pi-3-with-Raspbian-%28Debian-Jessie-8.0%29
>>
>> I wonder why creating buckets (containers) works well, but the upload
>> of a file fails because of "Permission denied".
>>
>> $ sudo swift-ring-builder /etc/swift/account.builder
>> /etc/swift/account.builder, build version 2
>> 256 partitions, 1.000000 replicas, 1 regions, 1 zones, 1 devices, 0.00
>> balance, 0.00 dispersion
>> The minimum number of hours before a partition can be reassigned is 0
>> (0:00:00 remaining)
>> The overload factor is 0.00% (0.000000)
>> Ring file /etc/swift/account.ring.gz is up-to-date
>> Devices:   id region zone ip address:port replication ip:port  name
>> weight partitions balance flags meta
>>             0      1    1  127.0.0.1:6012      127.0.0.1:6012    d1
>> 1.00        256    0.00
>>
>> $ sudo swift-ring-builder /etc/swift/container.builder
>> /etc/swift/container.builder, build version 2
>> 256 partitions, 1.000000 replicas, 1 regions, 1 zones, 1 devices, 0.00
>> balance, 0.00 dispersion
>> The minimum number of hours before a partition can be reassigned is 0
>> (0:00:00 remaining)
>> The overload factor is 0.00% (0.000000)
>> Ring file /etc/swift/container.ring.gz is up-to-date
>> Devices:   id region zone ip address:port replication ip:port  name
>> weight partitions balance flags meta
>>             0      1    1  127.0.0.1:6011      127.0.0.1:6011    d1
>> 1.00        256    0.00
>>
>> $ sudo swift-ring-builder /etc/swift/object.builder
>> /etc/swift/object.builder, build version 2
>> 256 partitions, 1.000000 replicas, 1 regions, 1 zones, 1 devices, 0.00
>> balance, 0.00 dispersion
>> The minimum number of hours before a partition can be reassigned is 0
>> (0:00:00 remaining)
>> The overload factor is 0.00% (0.000000)
>> Ring file /etc/swift/object.ring.gz is up-to-date
>> Devices:   id region zone ip address:port replication ip:port  name
>> weight partitions balance flags meta
>>             0      1    1  127.0.0.1:6010      127.0.0.1:6010    d1
>> 1.00        256    0.00
>>
>> $ nmap localhost -p 6010,6011,6012,8080,22
>> ...
>> PORT     STATE SERVICE
>> 22/tcp   open  ssh
>> 6010/tcp open  x11
>> 6011/tcp open  unknown
>> 6012/tcp open  unknown
>> 8080/tcp open  http-proxy
>>
>> What can i do to find the root cause of this issue and fix it?
>>
>> Best Regards
>>    Christian
>>
>> _______________________________________________
>> Mailing list: http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
>> Post to     : openstack@lists.openstack.org
>> Unsubscribe : http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack

_______________________________________________
Mailing list: http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack
Post to     : openstack@lists.openstack.org
Unsubscribe : http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack

Reply via email to