Why does root get "Permission denied" when trying to create this folder?

152

The answer is right there in the lsattr output:

# lsattr ..
----i--------e-- ../web2

The folder is immutable, even by root.

Share:
152

Related videos on Youtube

octavemirbeau
Author by

octavemirbeau

Updated on September 18, 2022

Comments

  • octavemirbeau
    octavemirbeau over 1 year

    I'm building a small webshop and I have the problem that I can't insert multiple order rows to a specific order due to the primary key constraint. How can I get around this? Out of convenience I would like to have the id autoincremented...

    CREATE TABLE order (
        id INT NOT NULL AUTO_INCREMENT,
        number INT,
        productid VARCHAR(15),
        customerid INT,
        created TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
        updated TIMESTAMP DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP,
        deleted TIMESTAMP DEFAULT NULL,
        ordered TIMESTAMP DEFAULT NULL,
        sent TIMESTAMP DEFAULT NULL,
        PRIMARY KEY (id),
        FOREIGN KEY (productid) REFERENCES product(produktid),
        FOREIGN KEY (customerid) REFERENCES customer(id)
    ) ENGINE INNODB CHARSET utf8 COLLATE utf8_swedish_ci;
    
    • sticky bit
      sticky bit about 4 years
      You'd typically have another table linking the products and their quantity to an order.
    • Gordon Linoff
      Gordon Linoff about 4 years
      What does your insert look like?
    • danblack
      danblack about 4 years
      Recommend "INT UNSIGNED" for AI values, you may was well get the full range.
  • kos
    kos about 9 years
    How does one deal with that by the way?
  • muru
    muru about 9 years
    @kos use chattr to remove the immutability attribute.
  • heemayl
    heemayl about 9 years
    @kos: You need chattr -i file