Uploaded image for project: 'Data Foundation Bugs'
  1. Data Foundation Bugs
  2. DFBUGS-2282

During upload of a dir when same name file exists, throwing NoSuchKey Exists error

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Undefined Undefined
    • None
    • odf-4.18.2
    • noobaa-nc
    • None
    • False
    • Hide

      None

      Show
      None
    • False
    • ?
    • ?
    • ?
    • ?
    • None

       

      Noobaa version: 5.18.2

       

      Steps to Reproduce:

      1. Create a bucket.
      2. Upload a file
      3. Delete/rename the file
      4. upload a directory with same file name

       

      Here is logs of execution:{}

      *******************************

      s3u9k s3 mb s3://demo-bucket-2
      urllib3/connectionpool.py:1064: InsecureRequestWarning: Unverified HTTPS request is being made to host '192.168.4.103'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/1.26.x/advanced-usage.html#ssl-warnings
      make_bucket: demo-bucket-2

      [root@pr523-41 ~]#
      [root@pr523-41 ~]# mkdir -p data/dir1/dir2/
      [root@pr523-41 ~]# echo "some datat..." >> data/dir1/dir2/file1.txt

      [root@pr523-41 ~]# s3u9k s3 cp data s3://demo-bucket-2
      upload failed: data/ to s3://demo-bucket-2/ Parameter validation failed:
      Invalid length for parameter Key, value: 0, valid min length: 1
      [root@pr523-41 ~]#
      [root@pr523-41 ~]# s3u9k s3 cp data s3://demo-bucket-2 --recursive
      urllib3/connectionpool.py:1064: InsecureRequestWarning: Unverified HTTPS request is being made to host '192.168.4.103'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/1.26.x/advanced-usage.html#ssl-warnings
      upload: data/dir1/dir2/file1.txt to s3://demo-bucket-2/dir1/dir2/file1.txt
      [root@pr523-41 ~]#
      [root@pr523-41 ~]# mv data/dir1/dir2/file1.txt data/dir1/dir2/file2.txt
      [root@pr523-41 ~]# mkdir -p data/dir1/dir2/file1.txt
      [root@pr523-41 ~]# mkdir -p data/dir1/dir2/
      [root@pr523-41 ~]#
      [root@pr523-41 ~]# cd data/dir1/dir2/
      [root@pr523-41 dir2]# ls -ltr
      total 8
      rw-rr-. 1 root root   14 Apr 17 14:48 file2.txt
      drwxr-xr-x. 2 root root 4096 Apr 17 14:51 file1.txt
      [root@pr523-41 dir2]# cd file1.txt/
      [root@pr523-41 file1.txt]# pwd
      /root/data/dir1/dir2/file1.txt
      [root@pr523-41 file1.txt]# echo "jdshjshd" >> xyz.txt
      [root@pr523-41 file1.txt]#
      [root@pr523-41 file1.txt]# ls -ltr
      total 4
      rw-rr-. 1 root root 9 Apr 17 14:52 xyz.txt
      [root@pr523-41 file1.txt]# cd /root/
      [root@pr523-41 ~]#
      [root@pr523-41 ~]# s3u9k s3 cp data s3://demo-bucket-2 --recursive
      urllib3/connectionpool.py:1064: InsecureRequestWarning: Unverified HTTPS request is being made to host '192.168.4.103'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/1.26.x/advanced-usage.html#ssl-warnings
      upload failed: data/dir1/dir2/file1.txt/xyz.txt to s3://demo-bucket-2/dir1/dir2/file1.txt/xyz.txt An error occurred (NoSuchKey) when calling the PutObject operation: The specified key does not exist.
      urllib3/connectionpool.py:1064: InsecureRequestWarning: Unverified HTTPS request is being made to host '192.168.4.103'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/1.26.x/advanced-usage.html#ssl-warnings
      upload: data/dir1/dir2/file2.txt to s3://demo-bucket-2/dir1/dir2/file2.txt

       

      The exact date and time when the issue was observed, including timezone details:

       

      Actual results:

      upload failed: data/dir1/dir2/file1.txt/xyz.txt to s3://demo-bucket-2/dir1/dir2/file1.txt/xyz.txt An error occurred (NoSuchKey) when calling the PutObject operation: The specified key does not exist.

       

      Expected results:

      Upload should pass or atleast throw a proper error

       

      Logs collected and log location:

      Logs are attached as exection in the section: steps to reproduce

      Additional info:

       
       

              jalbo@redhat.com Jacky Albo
              pravin.ranjan1@ibm.com Pravin Ranjan
              Votes:
              0 Vote for this issue
              Watchers:
              13 Start watching this issue

                Created:
                Updated: