title: How to check file owner in linux
body: <p>How to check file owner in linux</p>
  
  <p>i am trying to run this bash file</p>
  
  <pre><code>#!/bin/bash
  uname2=$(ls -l $1 | awk '{print $3}');
  if [ $uname2 == $USER ]
  then echo owner
  else echo no owner
  fi
  </code></pre>
  
  <p>it gives error ==' unary operator expected.
  what is wrong? ubuntu server 10.04.</p>