[Bug 1559079] [NEW] swiftclient.service upload leaks filehandles for large files

2016-03-18 Thread Chris Stratford
Public bug reported:

When uploading large files (i.e. multi-segment ones) using the
swiftclient.service functions, if you pass a file path instead of a file
object it seems to leave the files open after upload.

For example:
tmpfile = "/tmp/wibble"
obj = SwiftUploadObject(tmpfile, object_name=tmpfile)
swift.upload(container="mycontainer", objects=[obj])

After this, lsof shows /tmp/wibble is still open (multiple times)

This approach works around the problem:
with open(tmpfile, "r") as f:
obj = SwiftUploadObject(f, object_name=tmpfile)
swift.upload(container=container, objects=[obj]):

While I've seen this on the wily packaged version, it also appears to be
a problem in the upstream (3.0) python module.

$ lsb_release -rd
Description:Ubuntu 15.10
Release:15.10

$ apt-cache policy python-swiftclient
python-swiftclient:
  Installed: 1:2.6.0-1ubuntu1
  Candidate: 1:2.6.0-1ubuntu1
  Version table:
 *** 1:2.6.0-1ubuntu1 0
500 http://gb.archive.ubuntu.com/ubuntu/ wily/main amd64 Packages
100 /var/lib/dpkg/status

** Affects: python-swiftclient (Ubuntu)
 Importance: Undecided
 Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to python-swiftclient in Ubuntu.
https://bugs.launchpad.net/bugs/1559079

Title:
  swiftclient.service upload leaks filehandles for large files

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/python-swiftclient/+bug/1559079/+subscriptions

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs


[Bug 1388880] [NEW] metadata update should not delete large file manifest

2014-11-03 Thread Chris Stratford
Public bug reported:

If you upload a large file into swift using "swift -S" (or presumably
the upload() method) then add extra metadata using "swift post -m" (or
post_object()), the large file manifest metadata is deleted.  It
shouldn't do that.

$ swift upload -S 1000 chrisstest /boot/initrd.img-3.16.0-22-generic
boot/initrd.img-3.16.0-22-generic segment 3
boot/initrd.img-3.16.0-22-generic segment 0
boot/initrd.img-3.16.0-22-generic segment 1
boot/initrd.img-3.16.0-22-generic segment 2
/boot/initrd.img-3.16.0-22-generic

$ swift stat chrisstest boot/initrd.img-3.16.0-22-generic
   Account: AUTH_06b6c15ea8c54b8f9832cbaf1fb6
 Container: chrisstest
Object: boot/initrd.img-3.16.0-22-generic
  Content Type: application/octet-stream
Content Length: 30730085
 Last Modified: Mon, 03 Nov 2014 14:51:20 GMT
  ETag: "235bbbe8ab0520eec94a6bb8cc079db6"
  Manifest: 
chrisstest_segments/boot/initrd.img-3.16.0-22-generic/1413445437.00/30730085/1000/
Meta Mtime: 1413445437.00
 Accept-Ranges: bytes
   X-Timestamp: 1415026308.79456

$ swift post -m "x-object-meta-test1:test1" chrisstest
boot/initrd.img-3.16.0-22-generic

$ swift stat chrisstest boot/initrd.img-3.16.0-22-generic
 Account: AUTH_06b6c15ea8c54b8f9832cbaf1fb6
   Container: chrisstest
  Object: boot/initrd.img-3.16.0-22-generic
Content Type: application/octet-stream
  Content Length: 30730085
   Last Modified: Mon, 03 Nov 2014 14:53:52 GMT
ETag: 53d3910d4f2cea329b515f19cbb5ca89
Meta X-Object-Meta-Test1: test1
   Accept-Ranges: bytes
 X-Timestamp: 1415026432.67306

Interestingly, "swift download" (and the get_object() method) do re-
create the segmented file correctly even without the manifest (does it
just make an opportunistic look for chrisstest_segments?)


System details:

$ lsb_release -rd
Description:Ubuntu 14.10
Release:14.10

$ apt-cache policy python-swiftclient
python-swiftclient:
  Installed: 1:2.3.0-0ubuntu1
  Candidate: 1:2.3.0-0ubuntu1
  Version table:
 *** 1:2.3.0-0ubuntu1 0
500 http://gb.archive.ubuntu.com/ubuntu/ utopic/main amd64 Packages
100 /var/lib/dpkg/status

** Affects: swift (Ubuntu)
 Importance: Undecided
 Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to swift in Ubuntu.
https://bugs.launchpad.net/bugs/130

Title:
  metadata update should not delete large file manifest

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/swift/+bug/130/+subscriptions

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs


Re: [Bug 1078213] Re: logs are not logrotated

2014-10-02 Thread Chris Stratford
As an interim solution:

juju deploy cs:~chris-gondolin/trusty/logrotate
juju set logrotate='logfiles={"juju":{"path":"/var/log/juju/*.log"}}'


On 02/10/14 08:38, Haw Loeung wrote:
> ubuntu@juju-prod-XX-YYY-machine-0:/var/log/juju$ ls -la
> total 19790064
> drwxr-xr-x  2 syslog adm   4096 Oct  2 07:33 .
> drwxr-xr-x 11 root   root  4096 Oct  2 06:38 ..
> -rw-r--r--  1 syslog adm11719171973 Oct  2 07:33 all-machines.log.1
> -rw---  1 syslog syslog 879 Aug 18 20:17 ca-cert.pem
> -rw-r--r--  1 root   root  1757 Oct  2 07:33 machine-0.log
> -rw-r--r--  1 root   root8545817300 Oct  2 07:32 machine-0.log.1
> -rw---  1 syslog syslog 830 Aug 18 20:17 rsyslog-cert.pem
> -rw---  1 syslog syslog 887 Aug 18 20:17 rsyslog-key.pem

-- 
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to juju in Ubuntu.
https://bugs.launchpad.net/bugs/1078213

Title:
  logs are not logrotated

To manage notifications about this bug go to:
https://bugs.launchpad.net/juju-core/+bug/1078213/+subscriptions

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs


Re: [Bug 1287666] Re: qemu-nbd processes left behind after instance deletion

2014-03-07 Thread Chris Stratford
On 07/03/14 10:03, James Page wrote:

> I've seen this happen when the server can't resolve its own hostname,
> resulting in extra output in the sudo commands that nova uses to create
> nbd devices; is that potentially happening in your case as well?

Unless there was a temporary DNS glitch, this doesn't seem to be the
case.  The server can look up its own name happily and sudo doesn't show
any unexpected output for me.

Since it happened on more than one server at roughly the same time,
while I can't find any evidence in the logs to support it, an external
event (network glitch, busy firewall, etc.) is possible.

-- 
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to nova in Ubuntu.
https://bugs.launchpad.net/bugs/1287666

Title:
  qemu-nbd processes left behind after instance deletion

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/nova/+bug/1287666/+subscriptions

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs