[openstack-dev] The CI issue: “cp: cannot create regular file '/opt/stack/new/bin/etcd': Text file busy
Chris Smart
mail at csmart.io
Tue Oct 17 06:05:52 UTC 2017
On Tue, 17 Oct 2017, at 14:15, LinziWang at itri.org.tw wrote:
> and in the /%24LOG_PATH/logs/devstack-early.txt file,
> it shows
> 2017-10-17 02:49:21.324 | + lib/etcd3:install_etcd3:109: sudo cp
> /opt/stack/new/devstack/files/etcd-v3.1.10-linux-amd64/etcd
> /opt/stack/new/bin/etcd
> 2017-10-17 02:49:21.330 | cp: cannot create regular file
> '/opt/stack/new/bin/etcd': Text file busy
>
> Can anyone help me to resolve this issue?
> Why the file is busy???
>
The file is busy because the etcd binary at /opt/stack/new/bin/etcd is
currently being executed and therefore it cannot be replaced, as it has
an open handler on that file.
You can replicate this locally with a different binary, like this (using
the watch command):
$ cp /usr/bin/watch .
$ ./watch ls &
$ cp /usr/bin/watch .
cp: overwrite './watch'? y
cp: cannot create regular file './watch': Text file busy
Not that this is the right solution, but you can move it and then put
the new file in its place (the etcd will continue to run).
For example:
$ cp /usr/bin/watch .
$ ./watch ls &
$ mv watch watch-old
$ cp /usr/bin/watch .
$ ls watch*
watch watch-old
So, why is /opt/stack/new/bin/etcd already running on that host?...
-c
More information about the OpenStack-dev
mailing list